Commit a4bcf4d4 authored by Jérome Perrin's avatar Jérome Perrin

fixup! py2/py3: Make Products code compatible with both python2 and python3.

parent 237c93d4
...@@ -5,11 +5,7 @@ if brain.getValidationState() == 'embedded': ...@@ -5,11 +5,7 @@ if brain.getValidationState() == 'embedded':
else: else:
reference = brain.getReference() reference = brain.getReference()
import six return u"javascript:SelectFile('%s?format=%s')" % (
return six.text_type(
"javascript:SelectFile('%s?format=%s')" % (
reference.replace("'", "\\'"), reference.replace("'", "\\'"),
context.getPortalObject().portal_preferences.getPreferredImageFormat() context.getPortalObject().portal_preferences.getPreferredImageFormat(),
),
'utf-8',
) )
\ No newline at end of file
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