fix min password length check
This commit is contained in:
parent
d06fbcebb8
commit
c0614b18c3
@ -225,9 +225,8 @@ router.post(
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (body.password) {
|
if (body.password) {
|
||||||
const min = register.password.minLength
|
const min = register.password.minLength ?? 8;
|
||||||
? register.password.minLength
|
|
||||||
: 8;
|
|
||||||
if (body.password.length < min) {
|
if (body.password.length < min) {
|
||||||
throw FieldErrors({
|
throw FieldErrors({
|
||||||
password: {
|
password: {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user