Changeset - 40bccabf4574
[Not reviewed]
default
0 2 0
Marcin Kuzminski - 15 years ago 2010-07-14 15:42:39
marcin@python-works.com
fixed bug for user update, when password was always set.
2 files changed with 2 insertions and 2 deletions:
0 comments (0 inline, 0 general)
pylons_app/model/forms.py
Show inline comments
 
@@ -61,7 +61,8 @@ class ValidUsername(formencode.validator
 
class ValidPassword(formencode.validators.FancyValidator):
 
    
 
    def to_python(self, value, state):
 
        return get_crypt_password(value)
 
        if value:
 
            return get_crypt_password(value)
 
        
 
class ValidAuth(formencode.validators.FancyValidator):
 
    messages = {
pylons_app/model/user_model.py
Show inline comments
 
@@ -62,7 +62,6 @@ class UserModel(object):
 
                                  " crucial for entire application"))
 
            for k, v in form_data.items():
 
                if k == 'new_password' and v != '':
 
                    
 
                    new_user.password = v
 
                else:
 
                    setattr(new_user, k, v)
0 comments (0 inline, 0 general)