changeset 2758:dc4709e7da51 beta

fixed passing password via API create_user
author Marcin Kuzminski <marcin@python-works.com>
date Wed, 29 Aug 2012 00:56:00 +0200
parents 23e797c9496e
children c61c2ccea2b4
files rhodecode/controllers/api/api.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/rhodecode/controllers/api/api.py	Wed Aug 29 00:52:31 2012 +0200
+++ b/rhodecode/controllers/api/api.py	Wed Aug 29 00:56:00 2012 +0200
@@ -263,7 +263,7 @@
         if UserModel().get_by_email(email, case_insensitive=True):
             raise JSONRPCError("email `%s` already exist" % email)
 
-        if ldap_dn:
+        if Optional.extract(ldap_dn):
             # generate temporary password if ldap_dn
             password = PasswordGenerator().gen_password(length=8)