Commit 83544bb5 authored by Ivan Tyagov's avatar Ivan Tyagov

No need to use mimetypes_registry with hard coded name to get mime_type.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@37187 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 3a095522
......@@ -139,8 +139,7 @@ class PDFDocument(Image):
if not src_mimetype.endswith('png'):
continue
content = '%s' % png_data
mime_type = getToolByName(self, 'mimetypes_registry').\
lookupExtension('name.%s' % 'txt')
mime_type = 'text/plain'
if content is not None:
portal_transforms = getToolByName(self, 'portal_transforms')
result = portal_transforms.convertToData(mime_type, content,
......
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