# HG changeset patch # User Paul Boddie # Date 1445440473 -7200 # Node ID 29eebc30f864d0e2e9bbc9ba957946003410dade # Parent a64a3a62147f3b873a5dd622fdb4cbcd06d8a9e1 Added the local routing prefix to the configuration. diff -r a64a3a62147f -r 29eebc30f864 imiptools/config.py --- a/imiptools/config.py Wed Oct 21 15:22:09 2015 +0200 +++ b/imiptools/config.py Wed Oct 21 17:14:33 2015 +0200 @@ -6,6 +6,10 @@ MESSAGE_SENDER = "calendar@example.com" +# The local message handling prefix. + +LOCAL_PREFIX = "local" + # The outgoing message handling prefix. OUTGOING_PREFIX = "people-outgoing" diff -r a64a3a62147f -r 29eebc30f864 imiptools/mail.py --- a/imiptools/mail.py Wed Oct 21 15:22:09 2015 +0200 +++ b/imiptools/mail.py Wed Oct 21 17:14:33 2015 +0200 @@ -19,7 +19,7 @@ this program. If not, see . """ -from imiptools.config import MESSAGE_SENDER, OUTGOING_PREFIX +from imiptools.config import LOCAL_PREFIX, MESSAGE_SENDER, OUTGOING_PREFIX from email.mime.message import MIMEMessage from email.mime.multipart import MIMEMultipart from email.mime.text import MIMEText @@ -98,7 +98,7 @@ """ parts = recipient.split("+", 1) - return "%s+%s" % ("local", parts[-1]) + return "%s+%s" % (LOCAL_PREFIX, parts[-1]) def make_outgoing_message(self, parts, recipients, sender=None, outgoing_bcc=None):