Commit 8f40a79f authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

prevent "local variable 'output_format' referenced before assignment" error.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@42345 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ef636729
...@@ -80,6 +80,7 @@ class DownloadableMixin: ...@@ -80,6 +80,7 @@ class DownloadableMixin:
format = None format = None
self._checkConversionFormatPermission(format, **kw) self._checkConversionFormatPermission(format, **kw)
mime, data = self.convert(format, **kw) mime, data = self.convert(format, **kw)
output_format = None
if not format: if not format:
# Guess the format from original mimetype # Guess the format from original mimetype
mimetypes_registry = getToolByName(self.getPortalObject(), mimetypes_registry = getToolByName(self.getPortalObject(),
......
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