Merge pull request #78 from AdamNiederer/patch-2

Permissively Decode Emails
This commit is contained in:
Martin Rusev
2017-01-28 08:48:06 +01:00
committed by GitHub

View File

@@ -116,7 +116,7 @@ def decode_content(message):
content = message.get_payload(decode=True)
charset = message.get_content_charset('utf-8')
try:
return content.decode(charset)
return content.decode(charset, 'ignore')
except AttributeError:
return content