mirror of
https://github.com/coddingtonbear/django-mailbox.git
synced 2026-07-10 06:48:19 +02:00
Store 'Delivered-To' as 'to_header' when 'to' is unspecified.
This commit is contained in:
parent
df4c7196db
commit
e1b0763a46
1 changed files with 2 additions and 0 deletions
|
|
@ -320,6 +320,8 @@ class Mailbox(models.Model):
|
||||||
msg.from_header = convert_header_to_unicode(message['from'])
|
msg.from_header = convert_header_to_unicode(message['from'])
|
||||||
if 'to' in message:
|
if 'to' in message:
|
||||||
msg.to_header = convert_header_to_unicode(message['to'])
|
msg.to_header = convert_header_to_unicode(message['to'])
|
||||||
|
elif 'Delivered-To' in message:
|
||||||
|
msg.to_header = convert_header_to_unicode(message['Delivered-To'])
|
||||||
msg.save()
|
msg.save()
|
||||||
message = self._get_dehydrated_message(message, msg)
|
message = self._get_dehydrated_message(message, msg)
|
||||||
msg.set_body(message.as_string())
|
msg.set_body(message.as_string())
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue