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:
Pascal Fouque 2026-06-29 14:16:23 +02:00 committed by GitHub
commit 98684cd312
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 27 additions and 14 deletions

View file

@ -310,7 +310,7 @@ class Mailbox(models.Model):
)
elif (
settings['strip_unallowed_mimetypes']
and not msg.get_content_type() in settings['allowed_mimetypes']
and msg.get_content_type() not in settings['allowed_mimetypes']
):
for header, value in msg.items():
new[header] = value
@ -674,10 +674,9 @@ class Message(models.Model):
message.extra_headers['Date'] = formatdate()
message.extra_headers['In-Reply-To'] = self.message_id.strip()
message.send()
return self.mailbox.record_outgoing_message(
email.message_from_string(
message.message().as_string()
)
message.message()
)
@property