1
0
Fork 1
mirror of https://github.com/coddingtonbear/django-mailbox.git synced 2026-07-09 22:38:19 +02:00

Update models.py

This commit is contained in:
Manuel Gomez 2019-01-18 12:38:03 +01:00 committed by GitHub
parent 3f22f481e5
commit b390b28f11
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -356,7 +356,7 @@ class Mailbox(models.Model):
msg.subject = (
utils.convert_header_to_unicode(unicode(message['subject']).decode('utf-8'))[0:255]
)
msg.subject = repr(email.header.decode_header(msg.subject)[0][0])
msg.subject = repr(email.header.decode_header(msg.subject)[0][0]).replace("'", "")
if 'message-id' in message:
msg.message_id = message['message-id'][0:255].strip()
if 'from' in message: