summaryrefslogtreecommitdiffstats
path: root/ipalib/frontend.py
diff options
context:
space:
mode:
authorJason Gerard DeRose <jderose@redhat.com>2008-09-24 05:49:30 +0000
committerJason Gerard DeRose <jderose@redhat.com>2008-09-24 05:49:30 +0000
commit95abdcd7147399c9bb10adc2a04e41ddc97b2302 (patch)
tree240dc2c097a3ea19278b16d8772b36aa74333657 /ipalib/frontend.py
parent15b83ab1bf9d94e4f5cf292623d194b6a8094616 (diff)
downloadfreeipa-95abdcd7147399c9bb10adc2a04e41ddc97b2302.tar.gz
freeipa-95abdcd7147399c9bb10adc2a04e41ddc97b2302.tar.xz
freeipa-95abdcd7147399c9bb10adc2a04e41ddc97b2302.zip
330: Command.normalize() now normalizes all keys, not just keys in params
Diffstat (limited to 'ipalib/frontend.py')
-rw-r--r--ipalib/frontend.py11
1 files changed, 3 insertions, 8 deletions
diff --git a/ipalib/frontend.py b/ipalib/frontend.py
index fc397530a..f3264d81b 100644
--- a/ipalib/frontend.py
+++ b/ipalib/frontend.py
@@ -304,15 +304,10 @@ class Command(plugable.Plugin):
(k, self.params[k].convert(v)) for (k, v) in kw.iteritems()
)
- def __normalize_iter(self, kw):
- for (key, value) in kw.iteritems():
- if key in self.params:
- yield (key, self.params[key].normalize(value))
- else:
- yield (key, value)
-
def normalize(self, **kw):
- return dict(self.__normalize_iter(kw))
+ return dict(
+ (k, self.params[k].normalize(v)) for (k, v) in kw.iteritems()
+ )
def __get_default_iter(self, kw):
for param in self.params():