Backend camel case
This commit is contained in:
1 parent
c5b56dbc2b
commit
84613bc0e4
2 files changed
+6
-6
No files matched your search
@@ -3,11 +3,11 @@ const bcrypt = require("bcrypt");
|
||||
|
||||
const UserSchema = mongoose.Schema(
|
||||
{
|
||||
firstname: {
|
||||
firstName: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
lastname: {
|
||||
lastName: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
|
||||
@@ -28,11 +28,11 @@ const loginValidation = joi.object({
|
||||
});
|
||||
|
||||
const registerValidation = joi.object({
|
||||
firstname: joi
|
||||
firstName: joi
|
||||
.string()
|
||||
.required()
|
||||
.pattern(/^[A-Za-z]+$/),
|
||||
lastname: joi
|
||||
lastName: joi
|
||||
.string()
|
||||
.required()
|
||||
.pattern(/^[A-Za-z]+$/),
|
||||
@@ -53,8 +53,8 @@ const editUserParamValidation = joi.object({
|
||||
});
|
||||
|
||||
const editUserBodyValidation = joi.object({
|
||||
firstname: joi.string().pattern(/^[A-Za-z]+$/),
|
||||
lastname: joi.string().pattern(/^[A-Za-z]+$/),
|
||||
firstName: joi.string().pattern(/^[A-Za-z]+$/),
|
||||
lastName: joi.string().pattern(/^[A-Za-z]+$/),
|
||||
profileImage: joi.any(),
|
||||
newPassword: joi
|
||||
.string()
|
||||
|
||||
Reference in new issue
Block a user