diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2010-04-08 12:19:51 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2010-04-08 12:21:35 +0200 |
commit | 479fd9c03fc84824fea310b76d48ce271587cfe7 (patch) | |
tree | ed7431c6dd2ce2578252d8f04a09fcf32a9472a6 /source4/scripting/python/samba/netcmd/newuser.py | |
parent | 2578072541e880c83089fdd278d81467e91ddc5a (diff) | |
download | samba-479fd9c03fc84824fea310b76d48ce271587cfe7.tar.gz samba-479fd9c03fc84824fea310b76d48ce271587cfe7.tar.xz samba-479fd9c03fc84824fea310b76d48ce271587cfe7.zip |
s4-net: Simplify SamDB connect code.
Diffstat (limited to 'source4/scripting/python/samba/netcmd/newuser.py')
-rw-r--r-- | source4/scripting/python/samba/netcmd/newuser.py | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/source4/scripting/python/samba/netcmd/newuser.py b/source4/scripting/python/samba/netcmd/newuser.py index 6f12de50e79..3815219460f 100644 --- a/source4/scripting/python/samba/netcmd/newuser.py +++ b/source4/scripting/python/samba/netcmd/newuser.py @@ -59,12 +59,7 @@ class cmd_newuser(Command): lp = sambaopts.get_loadparm() creds = credopts.get_credentials(lp) - if H is not None: - url = H - else: - url = lp.get("sam database") - - samdb = SamDB(url=url, session_info=system_session(), credentials=creds, + samdb = SamDB(url=H, session_info=system_session(), credentials=creds, lp=lp) samdb.newuser(username, unixname, password, force_password_change_at_next_login_req=must_change_at_next_login) |