1
0
Fork 0

Allow message to be saved without attachments.

This commit is contained in:
Adam Coddington 2013-01-20 13:44:49 -08:00
parent a730abbb14
commit 25f1a71725
2 changed files with 6 additions and 3 deletions

View file

@ -256,7 +256,10 @@ class Message(models.Model):
null=True,
)
attachments = models.ManyToManyField(MessageAttachment)
attachments = models.ManyToManyField(
MessageAttachment,
blank=True,
)
objects = models.Manager()
unread_messages = UnreadMessageManager()
@ -321,4 +324,4 @@ class Message(models.Model):
return email.message_from_string(self.body)
def __unicode__(self):
return self.subject
return self.subject

View file

@ -4,7 +4,7 @@ tests_require=['django']
setup(
name='django-mailbox',
version='1.6.1',
version='1.6.2',
url='http://bitbucket.org/latestrevision/django-mailbox/',
description='Import mail from POP3, IMAP, local mailboxes or directly from Postfix or Exim4 into your Django application automatically.',
author='Adam Coddington',