From 473ef5fd0ff7c6888c4d1307ee65ea9b1f578827 Mon Sep 17 00:00:00 2001 From: Kali Kaneko Date: Tue, 11 Feb 2014 01:39:43 -0400 Subject: fix repeated recent flag --- mail/src/leap/mail/imap/mailbox.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'mail/src') diff --git a/mail/src/leap/mail/imap/mailbox.py b/mail/src/leap/mail/imap/mailbox.py index 018f88e..fa97512 100644 --- a/mail/src/leap/mail/imap/mailbox.py +++ b/mail/src/leap/mail/imap/mailbox.py @@ -854,12 +854,13 @@ class SoledadMailbox(WithMsgFields, MBoxParser): else: mbox = self.mbox uid_next = memstore.increment_last_soledad_uid(mbox) + new_fdoc[self.UID_KEY] = uid_next new_fdoc[self.MBOX_KEY] = mbox flags = list(new_fdoc[self.FLAGS_KEY]) flags.append(fields.RECENT_FLAG) - new_fdoc[self.FLAGS_KEY] = flags + new_fdoc[self.FLAGS_KEY] = tuple(set(flags)) # FIXME set recent! @@ -896,7 +897,8 @@ class SoledadMailbox(WithMsgFields, MBoxParser): dest_fdoc = memstore.get_fdoc_from_chash( fdoc_chash, self.mbox) - exist = dest_fdoc and not empty(dest_fdoc.content) + + exist = not empty(dest_fdoc) return exist, new_fdoc # convenience fun -- cgit v1.2.3