Mercurial > public > src > rhodecode
changeset 334:90fb24ac357a demo
Updated demo to manage users without changing password
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Tue, 29 Jun 2010 21:00:31 +0200 |
parents | 4402f4041696 |
children | 27ef9dd22ca2 |
files | pylons_app/model/user_model.py |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/pylons_app/model/user_model.py Tue Jun 29 20:57:19 2010 +0200 +++ b/pylons_app/model/user_model.py Tue Jun 29 21:00:31 2010 +0200 @@ -62,8 +62,9 @@ " crucial for entire application")) for k, v in form_data.items(): if k == 'new_password' and v != '': - - new_user.password = v + #demo application protection + if new_user.username != 'demo': + new_user.password = v else: setattr(new_user, k, v)