summaryrefslogtreecommitdiff
path: root/src/leap/mail/imap/mailbox.py
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2015-09-21 17:22:23 -0400
committerKali Kaneko <kali@leap.se>2015-09-21 17:22:37 -0400
commit5bc9889e3afe9f9bcc39c60b819de18c46d0322a (patch)
tree241151b823b75f752c745e7e2f340ada7a1e5012 /src/leap/mail/imap/mailbox.py
parent36966a403237307a68359cac97a718462b2e02e3 (diff)
[bug] filter out Nones in the sequence of messages
Diffstat (limited to 'src/leap/mail/imap/mailbox.py')
-rw-r--r--src/leap/mail/imap/mailbox.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/leap/mail/imap/mailbox.py b/src/leap/mail/imap/mailbox.py
index c52a2e3..e73994b 100644
--- a/src/leap/mail/imap/mailbox.py
+++ b/src/leap/mail/imap/mailbox.py
@@ -558,7 +558,8 @@ class IMAPMailbox(object):
def _get_imap_msg(messages):
d_imapmsg = []
- for msg in messages:
+ # just in case we got bad data in here
+ for msg in filter(None, messages):
d_imapmsg.append(getimapmsg(msg))
return defer.gatherResults(d_imapmsg, consumeErrors=True)