diff options
Diffstat (limited to 'Mailman/Handlers/ToArchive.py')
-rw-r--r-- | Mailman/Handlers/ToArchive.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/Mailman/Handlers/ToArchive.py b/Mailman/Handlers/ToArchive.py index cdee793f..59bf680f 100644 --- a/Mailman/Handlers/ToArchive.py +++ b/Mailman/Handlers/ToArchive.py @@ -19,7 +19,10 @@ import time from cStringIO import StringIO +from email import message_from_string + from Mailman import mm_cfg +from Mailman import Message from Mailman.Queue.sbcache import get_switchboard @@ -36,4 +39,10 @@ def process(mlist, msg, msgdata): # Send the message to the archiver queue archq = get_switchboard(mm_cfg.ARCHQUEUE_DIR) # Send the message to the queue - archq.enqueue(msg, msgdata) + if msg.get('x-mailman-scrubbed'): + # Clean Scrubber-munged message. + archmsg = message_from_string(msg.as_string(), Message.Message) + del archmsg['x-mailman-scrubbed'] + archq.enqueue(archmsg, msgdata) + else: + archq.enqueue(msg, msgdata) |