fix: 修改SECURITY_PASSWORD_MIN_LENGTH

This commit is contained in:
Bai
2021-08-05 10:37:29 +08:00
committed by Jiangjie.Bai
parent 66b499b8e3
commit 8ad78ffef8

View File

@@ -322,7 +322,7 @@ def check_password_rules(password, user):
if user.is_org_admin:
min_length = settings.SECURITY_ADMIN_USER_PASSWORD_MIN_LENGTH
else:
min_length = settings.SECURITY_PASSWORD_MIN_LEN
min_length = settings.SECURITY_PASSWORD_MIN_LENGTH
pattern += '.{' + str(min_length-1) + ',}$'
match_obj = re.match(pattern, password)
return bool(match_obj)