aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/middlewares/validators/users.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/middlewares/validators/users.ts')
-rw-r--r--server/middlewares/validators/users.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/middlewares/validators/users.ts b/server/middlewares/validators/users.ts
index db03dc231..da92c715d 100644
--- a/server/middlewares/validators/users.ts
+++ b/server/middlewares/validators/users.ts
@@ -2,7 +2,7 @@ import * as Bluebird from 'bluebird'
2import * as express from 'express' 2import * as express from 'express'
3import { body, param } from 'express-validator' 3import { body, param } from 'express-validator'
4import { omit } from 'lodash' 4import { omit } from 'lodash'
5import { isIdOrUUIDValid, toIntOrNull } from '../../helpers/custom-validators/misc' 5import { isIdOrUUIDValid, toBooleanOrNull, toIntOrNull } from '../../helpers/custom-validators/misc'
6import { 6import {
7 isUserAdminFlagsValid, 7 isUserAdminFlagsValid,
8 isUserAutoPlayVideoValid, 8 isUserAutoPlayVideoValid,
@@ -357,7 +357,7 @@ const usersVerifyEmailValidator = [
357 .not().isEmpty().withMessage('Should have a valid verification string'), 357 .not().isEmpty().withMessage('Should have a valid verification string'),
358 body('isPendingEmail') 358 body('isPendingEmail')
359 .optional() 359 .optional()
360 .customSanitizer(toIntOrNull), 360 .customSanitizer(toBooleanOrNull),
361 361
362 async (req: express.Request, res: express.Response, next: express.NextFunction) => { 362 async (req: express.Request, res: express.Response, next: express.NextFunction) => {
363 logger.debug('Checking usersVerifyEmail parameters', { parameters: req.params }) 363 logger.debug('Checking usersVerifyEmail parameters', { parameters: req.params })