chore: relocate backend into apps/api ahead of monorepo merge

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-24 12:20:40 +08:00
co-authored by Claude Sonnet 5
parent af44598df6
commit eaa6d2276a
388 changed files with 0 additions and 13998 deletions
+19
View File
@@ -0,0 +1,19 @@
/***********************************************************************************************************************************************************************
* File Name: profile.validator.js
* Type of Program: Validator
* Description: express-validator rule chains for profile update endpoints.
* Author: rgrgogu
* Date Created: Oct. 6, 2025
***********************************************************************************************************************************************************************/
const { body } = require('express-validator');
const updateProfileValidator = [
body('personal_info').optional().isObject().withMessage('personal_info must be an object.'),
body('personal_info.name').optional().isObject(),
body('personal_info.name.given_name').optional().isString().trim().isLength({ max: 100 }),
body('personal_info.name.last_name').optional().isString().trim().isLength({ max: 100 }),
body('personal_info.occupation').optional().isString().trim().isLength({ max: 150 }),
body('personal_info.date_of_birth').optional().isDate().withMessage('date_of_birth must be a valid date.'),
];
module.exports = { updateProfileValidator };