summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPetr Viktorin <pviktori@redhat.com>2013-11-26 23:31:05 +0100
committerMartin Kosek <mkosek@redhat.com>2014-01-03 14:11:33 +0100
commit7ec4d58bf71077da5859ab798640479955fbdd48 (patch)
treea7ac66898151a8378902b1eb579c5dab62d4644f
parent0accfabfa3fff0993b64e8bc13c718ac0054f3d4 (diff)
downloadfreeipa-7ec4d58bf71077da5859ab798640479955fbdd48.tar.gz
freeipa-7ec4d58bf71077da5859ab798640479955fbdd48.tar.xz
freeipa-7ec4d58bf71077da5859ab798640479955fbdd48.zip
cli.print_attribute: Convert values to strings
When output_for_cli was called directly, rather than for values received through XML or JSON API, joining multiple values failed on non-strings such as DN objects. Convert output to strings before printing it out.
-rw-r--r--ipalib/cli.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ipalib/cli.py b/ipalib/cli.py
index 78f2949d2..4cf007d31 100644
--- a/ipalib/cli.py
+++ b/ipalib/cli.py
@@ -293,7 +293,7 @@ class textui(backend.Backend):
return
else:
if len(value) > 0:
- text = ', '.join(value)
+ text = ', '.join(str(v) for v in value)
else:
return
line_len = self.get_tty_width()