mirror of
https://github.com/django-helpdesk/django-helpdesk.git
synced 2024-12-13 18:31:10 +01:00
Fixes issue #100: Non-ASCII characters in HTML email caused an exception
to be thrown when importing emails.
This commit is contained in:
parent
dc5ea4306a
commit
2c723e85bb
@ -184,7 +184,7 @@ def ticket_from_message(message, queue, quiet):
|
|||||||
if part.get_content_subtype() == 'plain':
|
if part.get_content_subtype() == 'plain':
|
||||||
body_plain = decodeUnknown(part.get_charset(), part.get_payload(decode=True))
|
body_plain = decodeUnknown(part.get_charset(), part.get_payload(decode=True))
|
||||||
else:
|
else:
|
||||||
body_html = decodeUnknown(part.get_charset(), part.get_payload(decode=True))
|
body_html = part.get_payload(decode=True)
|
||||||
else:
|
else:
|
||||||
if not name:
|
if not name:
|
||||||
ext = mimetypes.guess_extension(part.get_content_type())
|
ext = mimetypes.guess_extension(part.get_content_type())
|
||||||
|
Loading…
Reference in New Issue
Block a user