diff options
author | eug-vs <eug-vs@keemail.me> | 2020-08-08 11:25:34 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2020-08-08 11:25:34 +0300 |
commit | ef5666b96e971254c112458f39cfd9b329080bf0 (patch) | |
tree | 1e74ad306fda272dff64467b5b34ffe83300ad2d | |
parent | 6b04525bf529baca8d2fa2d591f3162bd4d88d4f (diff) | |
download | which-api-ef5666b96e971254c112458f39cfd9b329080bf0.tar.gz |
feat!: only allow lowercase usernames
-rw-r--r-- | models/users/user.schema.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/models/users/user.schema.ts b/models/users/user.schema.ts index 5969604..f6a1c09 100644 --- a/models/users/user.schema.ts +++ b/models/users/user.schema.ts @@ -9,7 +9,8 @@ export const userSchema = new Schema({ username: { type: String, unique: true, - required: true + required: true, + lowercase: true }, password: { type: String, |