Skip to content

Commit ef5666b

Browse files
committed
feat!: only allow lowercase usernames
1 parent 6b04525 commit ef5666b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

models/users/user.schema.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@ export const userSchema = new Schema({
99
username: {
1010
type: String,
1111
unique: true,
12-
required: true
12+
required: true,
13+
lowercase: true
1314
},
1415
password: {
1516
type: String,

0 commit comments

Comments
 (0)