summaryrefslogtreecommitdiff
path: root/src/leap/mail/constants.py
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2015-01-12 20:47:29 -0400
committerKali Kaneko <kali@leap.se>2015-02-11 14:05:43 -0400
commitf7030295a936cc5da33f50411b5ff60ae0eec7cc (patch)
tree43bc7699b79185729ac62860374ee43a19f917d9 /src/leap/mail/constants.py
parent9e2cf40db51889ec43cd4e27b55c7f14e0436c01 (diff)
Use mailbox uuids
The previous implementation is naive, since it imposes a burden when renaming mailboxes. We're using uuids in the local uid tables instead, which is more cryptic but way more efficient. * receive mbox uuid instead of name * use mailbox uuid in identifiers
Diffstat (limited to 'src/leap/mail/constants.py')
-rw-r--r--src/leap/mail/constants.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/leap/mail/constants.py b/src/leap/mail/constants.py
index d76e652..4ef42cb 100644
--- a/src/leap/mail/constants.py
+++ b/src/leap/mail/constants.py
@@ -22,13 +22,13 @@ INBOX_NAME = "INBOX"
# Regular expressions for the identifiers to be used in the Message Data Layer.
-METAMSGID = "M-{mbox}-{chash}"
-METAMSGID_RE = "M\-{mbox}\-[0-9a-fA-F]+"
+METAMSGID = "M-{mbox_uuid}-{chash}"
+METAMSGID_RE = "M\-{mbox_uuid}\-[0-9a-fA-F]+"
METAMSGID_CHASH_RE = "M\-\w+\-([0-9a-fA-F]+)"
METAMSGID_MBOX_RE = "M\-(\w+)\-[0-9a-fA-F]+"
-FDOCID = "F-{mbox}-{chash}"
-FDOCID_RE = "F\-{mbox}\-[0-9a-fA-F]+"
+FDOCID = "F-{mbox_uuid}-{chash}"
+FDOCID_RE = "F\-{mbox_uuid}\-[0-9a-fA-F]+"
FDOCID_CHASH_RE = "F\-\w+\-([0-9a-fA-F]+)"
HDOCID = "H-{chash}"