made last name optional

This commit is contained in:
Sheen Capadngan
2023-05-15 20:39:45 +08:00
parent 9dc7cc58a7
commit 884aed74a5
+2 -1
View File
@@ -10,7 +10,7 @@ router.post(
authLimiter, authLimiter,
body('email').exists().isString().trim().notEmpty().isEmail(), body('email').exists().isString().trim().notEmpty().isEmail(),
body('firstName').exists().isString().trim().notEmpty(), body('firstName').exists().isString().trim().notEmpty(),
body('lastName').exists().isString().trim().notEmpty(), body('lastName').exists().isString().trim().optional({nullable: true}),
body('protectedKey').exists().isString().trim().notEmpty(), body('protectedKey').exists().isString().trim().notEmpty(),
body('protectedKeyIV').exists().isString().trim().notEmpty(), body('protectedKeyIV').exists().isString().trim().notEmpty(),
body('protectedKeyTag').exists().isString().trim().notEmpty(), body('protectedKeyTag').exists().isString().trim().notEmpty(),
@@ -21,6 +21,7 @@ router.post(
body('salt').exists().isString().trim().notEmpty(), body('salt').exists().isString().trim().notEmpty(),
body('verifier').exists().isString().trim().notEmpty(), body('verifier').exists().isString().trim().notEmpty(),
body('organizationName').exists().isString().trim().notEmpty(), body('organizationName').exists().isString().trim().notEmpty(),
body('providerAuthToken').isString().trim().optional({nullable: true}),
validateRequest, validateRequest,
signupController.completeAccountSignup, signupController.completeAccountSignup,
); );