summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRuben Pollan <meskio@sindominio.net>2015-07-03 17:10:05 -0400
committerRuben Pollan <meskio@sindominio.net>2015-07-03 17:10:05 -0400
commit0cbea9f5726fc9507f98d06d5db937e9bf292a1a (patch)
tree703c24981b3c2525956a4d6e8a3e3913e82d1bcd
parent1525d66223187cc54e91a5b3c55bf7ae4e8b471e (diff)
[bug] notify copied emails
When copying emails there was not notification produced, that makes thunderbird to see messages moved between folders until it gets restarted. Now the MaillCollection copy does notify the listeners. * Resolves: #7158
-rw-r--r--mail/src/leap/mail/mail.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/mail/src/leap/mail/mail.py b/mail/src/leap/mail/mail.py
index 1a60c6db..2f190d4b 100644
--- a/mail/src/leap/mail/mail.py
+++ b/mail/src/leap/mail/mail.py
@@ -619,8 +619,8 @@ class MessageCollection(object):
doc_id = wrapper.mdoc.doc_id
if not doc_id:
# --- BUG -----------------------------------------
- # XXX why from time to time mdoc doesn't have doc_id
- # here???
+ # XXX watch out, sometimes mdoc doesn't have doc_id
+ # but it has future_id. Should be solved already.
logger.error("BUG: (please report) Null doc_id for "
"document %s" %
(wrapper.mdoc.serialize(),))
@@ -742,6 +742,7 @@ class MessageCollection(object):
d = wrapper.copy(self.store, new_mbox_uuid)
d.addCallback(insert_copied_mdoc_id)
+ d.addCallback(self.notify_new_to_listeners)
return d
def delete_msg(self, msg):