##// END OF EJS Templates
fixed bug for user update, when password was always set.
marcink -
r347:40bccabf default
parent child Browse files
Show More
@@ -61,7 +61,8 b' class ValidUsername(formencode.validator'
61 61 class ValidPassword(formencode.validators.FancyValidator):
62 62
63 63 def to_python(self, value, state):
64 return get_crypt_password(value)
64 if value:
65 return get_crypt_password(value)
65 66
66 67 class ValidAuth(formencode.validators.FancyValidator):
67 68 messages = {
@@ -62,7 +62,6 b' class UserModel(object):'
62 62 " crucial for entire application"))
63 63 for k, v in form_data.items():
64 64 if k == 'new_password' and v != '':
65
66 65 new_user.password = v
67 66 else:
68 67 setattr(new_user, k, v)
General Comments 0
You need to be logged in to leave comments. Login now