mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-07-30 11:19:44 -04:00
Updated error message is the code is not the right size or data type.
Updated two_factor to error is the user account is locked (locked = over 10 failed_login_count)
This commit is contained in:
@@ -118,14 +118,7 @@ def sms_code():
|
||||
return StringField('Text message code',
|
||||
validators=[DataRequired(message='Can’t be empty'),
|
||||
Regexp(regex=verify_code,
|
||||
message='Must be 5 digits')])
|
||||
|
||||
|
||||
def email_code():
|
||||
verify_code = '^\d{5}$'
|
||||
return StringField("Email code",
|
||||
validators=[DataRequired(message='Can’t be empty'),
|
||||
Regexp(regex=verify_code, message='Must be 5 digits')])
|
||||
message='Code not found')])
|
||||
|
||||
|
||||
class LoginForm(Form):
|
||||
|
||||
Reference in New Issue
Block a user