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.
This commit is contained in:
Petr Viktorin authored and Martin Kosek committed 2014-01-03 14:11:33 +01:00
1 parent 0accfabfa3
commit 7ec4d58bf7
1 file changed
+1 -1
+1 -1
View File
@@ -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()