This commit is contained in:
Girish Ramakrishnan
2022-11-30 14:56:40 +01:00
parent 2a660fa59d
commit 69b46d82ab
2 changed files with 2 additions and 2 deletions

View File

@@ -300,7 +300,7 @@ async function prepareDashboardDomain(req, res, next) {
}
async function renewCerts(req, res, next) {
if ('rebuild' in req.body && typeof req.body !== 'boolean') return next(new HttpError(400, 'rebuild must be a boolean'));
if ('rebuild' in req.body && typeof req.body.rebuild !== 'boolean') return next(new HttpError(400, 'rebuild must be a boolean'));
const [error, taskId] = await safe(cloudron.renewCerts(req.body, AuditSource.fromRequest(req)));
if (error) return next(BoxError.toHttpError(error));