Commit 40fded3e authored by Yusei Tahara's avatar Yusei Tahara

erp5_core: Fix unicode bug on ZODB History view.

parent d6186232
Pipeline #24184 failed with stage
in 0 seconds
...@@ -13,7 +13,7 @@ def beautifyChange(change_dict): ...@@ -13,7 +13,7 @@ def beautifyChange(change_dict):
for property_name, property_value in sorted(change_dict.items()): for property_name, property_value in sorted(change_dict.items()):
if isinstance(property_value, six.binary_type): if isinstance(property_value, six.binary_type):
try: try:
six.text_type(property_value, 'utf-8') property_value = six.text_type(property_value, 'utf-8')
except UnicodeDecodeError: except UnicodeDecodeError:
property_value = '(binary)' property_value = '(binary)'
change_list.append('%s:%s' % (property_name, property_value)) change_list.append('%s:%s' % (property_name, property_value))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment