def validate_new_password(form, field):
"""
Validates the new password entered
:param form: The form which is being passed in
:type form: AccountForm
:param field: The data value for the 'password' entered by User
:type field : PasswordField
"""
if len(field.data) == 0 and len(form.new_password_repeat.data) == 0:
return
valid_password(form, field)
评论列表
文章目录