1
0
Fork 1
mirror of https://github.com/coddingtonbear/django-mailbox.git synced 2026-07-10 06:48:19 +02:00
This commit is contained in:
ptav 2025-06-20 07:09:42 +02:00 committed by GitHub
commit 5427b059cf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 0 deletions

View file

@ -374,6 +374,12 @@ class Mailbox(models.Model):
content_charset = msg.get_content_charset()
if not content_charset:
content_charset = 'ascii'
elif content_charset == 'iso-8859-8-i':
content_charset = 'iso-8859-8'
logger.warning(
"Unhandled encoding %s; interpreting as iso-8859-8",
content_charset
)
try:
# Make sure that the payload can be properly decoded in the
# defined charset, if it can't, let's mash some things