diff options
author | Ruben Pollan <meskio@sindominio.net> | 2015-06-15 21:24:00 +0200 |
---|---|---|
committer | Ruben Pollan <meskio@sindominio.net> | 2015-06-15 21:24:00 +0200 |
commit | 0ebb84463b92b7251936e93c31a6b9c569ba0a54 (patch) | |
tree | adf90dabed9caa9ebdb75c37eba7055b030930ac /src/leap/mail/imap | |
parent | d5d9c3794566b999bfd42398072c9f7e3177d1b9 (diff) | |
parent | 061024899e29f745b3c375930b60247de36e2fd3 (diff) |
Merge branch 'feature/post-sync-hooks' into develop
Diffstat (limited to 'src/leap/mail/imap')
-rw-r--r-- | src/leap/mail/imap/account.py | 7 | ||||
-rw-r--r-- | src/leap/mail/imap/service/imap.py | 4 |
2 files changed, 6 insertions, 5 deletions
diff --git a/src/leap/mail/imap/account.py b/src/leap/mail/imap/account.py index ccb4b75..cc56fff 100644 --- a/src/leap/mail/imap/account.py +++ b/src/leap/mail/imap/account.py @@ -58,7 +58,6 @@ class IMAPAccount(object): implements(imap4.IAccount, imap4.INamespacePresenter) selected = None - session_ended = False def __init__(self, user_id, store, d=defer.Deferred()): """ @@ -98,7 +97,11 @@ class IMAPAccount(object): Right now it's called from the client backend. """ # TODO move its use to the service shutdown in leap.mail - self.session_ended = True + self.account.end_session() + + @property + def session_ended(self): + return self.account.session_ended def callWhenReady(self, cb, *args, **kw): """ diff --git a/src/leap/mail/imap/service/imap.py b/src/leap/mail/imap/service/imap.py index 370c513..92d05cc 100644 --- a/src/leap/mail/imap/service/imap.py +++ b/src/leap/mail/imap/service/imap.py @@ -32,10 +32,9 @@ from twisted.python import log logger = logging.getLogger(__name__) from leap.common.events import emit, catalog -from leap.common.check import leap_assert_type, leap_check +from leap.common.check import leap_check from leap.mail.imap.account import IMAPAccount from leap.mail.imap.server import LEAPIMAPServer -from leap.soledad.client import Soledad DO_MANHOLE = os.environ.get("LEAP_MAIL_MANHOLE", None) @@ -91,7 +90,6 @@ class LeapIMAPFactory(ServerFactory): theAccount = IMAPAccount(uuid, soledad) self.theAccount = theAccount - self._connections = defaultdict() # XXX how to pass the store along? |