summaryrefslogtreecommitdiff
path: root/service/pixelated/adapter/soledad/soledad_facade_mixin.py
diff options
context:
space:
mode:
Diffstat (limited to 'service/pixelated/adapter/soledad/soledad_facade_mixin.py')
-rw-r--r--service/pixelated/adapter/soledad/soledad_facade_mixin.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/service/pixelated/adapter/soledad/soledad_facade_mixin.py b/service/pixelated/adapter/soledad/soledad_facade_mixin.py
index 280fc81e..761ef1e2 100644
--- a/service/pixelated/adapter/soledad/soledad_facade_mixin.py
+++ b/service/pixelated/adapter/soledad/soledad_facade_mixin.py
@@ -59,8 +59,10 @@ class SoledadDbFacadeMixin(object):
def get_mbox(self, mbox):
return self.soledad.get_from_index('by-type-and-mbox', 'mbox', mbox) if mbox else []
- def get_lastuid(self, mbox_doc):
- return mbox_doc.content['lastuid']
+ def get_lastuid(self, mbox):
+ if isinstance(mbox, str):
+ mbox = self.get_mbox(mbox)[0]
+ return mbox.content['lastuid']
def get_search_index_masterkey(self):
return self.soledad.get_from_index('by-type', 'index_key')