From a53bc0a91bea89f0f284429c8fe2678891dd239b Mon Sep 17 00:00:00 2001 From: Matthias Dieter Wallnöfer Date: Mon, 7 Nov 2011 17:57:52 +0100 Subject: s4:samba-tool - other fix for Gémes Géza patch regarding parameter handling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The condition has not been specified correctly since we are expecting a boolean. Pointed out by Jelmer. Reviewed-by: Jelmer --- source4/scripting/python/samba/netcmd/user.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source4/scripting/python/samba/netcmd/user.py b/source4/scripting/python/samba/netcmd/user.py index 0ac4b23742..e45b3bfb75 100644 --- a/source4/scripting/python/samba/netcmd/user.py +++ b/source4/scripting/python/samba/netcmd/user.py @@ -106,7 +106,7 @@ Example3 shows how to create a new user in the OrgUnit organizational unit. job_title=None, department=None, company=None, description=None, mail_address=None, internet_address=None, telephone_number=None, physical_delivery_office=None): - if random_password is True: + if random_password: password = generate_random_password(128, 255) while 1: @@ -401,7 +401,7 @@ Example3 shows how an administrator would reset TestUser3 user's password to pas if filter is None and username is None: raise CommandError("Either the username or '--filter' must be specified!") - if random_password is True: + if random_password: password = generate_random_password(128, 255) else: password = newpassword -- cgit