summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/mail/incoming/service.py
diff options
context:
space:
mode:
authorRuben Pollan <meskio@sindominio.net>2017-01-12 15:19:02 +0100
committerKali Kaneko (leap communications) <kali@leap.se>2017-02-09 12:00:57 +0100
commit15662055b24b1bf4b6007a6a07b642234b264521 (patch)
tree77762b106364c8ff9103d0c836fe7fc6977664ea /src/leap/bitmask/mail/incoming/service.py
parent776febf6970deeef999255392c6480d1ff34c6f6 (diff)
[feat] Get more detailed status report for email
- Resolves: #8754
Diffstat (limited to 'src/leap/bitmask/mail/incoming/service.py')
-rw-r--r--src/leap/bitmask/mail/incoming/service.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/leap/bitmask/mail/incoming/service.py b/src/leap/bitmask/mail/incoming/service.py
index 4807c8f7..ac7a5d18 100644
--- a/src/leap/bitmask/mail/incoming/service.py
+++ b/src/leap/bitmask/mail/incoming/service.py
@@ -205,6 +205,13 @@ class IncomingMail(Service):
self._loop = None
Service.stopService(self)
+ def unread(self):
+ """
+ :returns: a deferred that will be fired with the number of unread
+ messages
+ """
+ return self._inbox_collection.count_unseen()
+
#
# Private methods.
#