summaryrefslogtreecommitdiffstats
path: root/ipalib/cli.py
diff options
context:
space:
mode:
authorJan Cholasta <jcholast@redhat.com>2016-04-06 15:26:48 +0200
committerJan Cholasta <jcholast@redhat.com>2016-05-25 16:06:26 +0200
commitac2e9e84cf67b59488a07ffe932019ce3e23b41a (patch)
treec73ab49d3c9be49308360ec5eb7b90efd3a82b8e /ipalib/cli.py
parent213237c7fe053b43589de4bc64a871861da6db9a (diff)
downloadfreeipa-ac2e9e84cf67b59488a07ffe932019ce3e23b41a.tar.gz
freeipa-ac2e9e84cf67b59488a07ffe932019ce3e23b41a.tar.xz
freeipa-ac2e9e84cf67b59488a07ffe932019ce3e23b41a.zip
frontend: do not forward argument defaults to server
When forwarding a command call to a server, use only arguments which were explicitly specified by the caller. This increases compatibility between new clients and old servers. https://fedorahosted.org/freeipa/ticket/4739 Reviewed-By: David Kupka <dkupka@redhat.com>
Diffstat (limited to 'ipalib/cli.py')
-rw-r--r--ipalib/cli.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/ipalib/cli.py b/ipalib/cli.py
index 3692e4e53..1c88a9b1f 100644
--- a/ipalib/cli.py
+++ b/ipalib/cli.py
@@ -1243,6 +1243,8 @@ class cli(backend.Executioner):
if param.autofill:
kw[param.name] = cmd.get_default_of(param.name, **kw)
if param.name in kw and kw[param.name] is not None:
+ if param.autofill:
+ del kw[param.name]
continue
if param.password:
kw[param.name] = self.Backend.textui.prompt_password(