summaryrefslogtreecommitdiff
path: root/src/mailman/handlers/to_archive.py
diff options
context:
space:
mode:
authorBarry Warsaw2012-08-18 19:32:53 -0400
committerBarry Warsaw2012-08-18 19:32:53 -0400
commitb301eeb71249ef58ffcc8b285d51b19c8b42812b (patch)
tree56552098758969669957f6ba0a175bc2cdbea19d /src/mailman/handlers/to_archive.py
parentffd6b7b2ec632920cbf9d413aa20d83d8333c87f (diff)
downloadmailman-b301eeb71249ef58ffcc8b285d51b19c8b42812b.tar.gz
mailman-b301eeb71249ef58ffcc8b285d51b19c8b42812b.tar.zst
mailman-b301eeb71249ef58ffcc8b285d51b19c8b42812b.zip
Diffstat (limited to 'src/mailman/handlers/to_archive.py')
-rw-r--r--src/mailman/handlers/to_archive.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mailman/handlers/to_archive.py b/src/mailman/handlers/to_archive.py
index 0dc5bad1a..5718557fa 100644
--- a/src/mailman/handlers/to_archive.py
+++ b/src/mailman/handlers/to_archive.py
@@ -29,6 +29,7 @@ from zope.interface import implementer
from mailman.config import config
from mailman.core.i18n import _
+from mailman.interfaces.archiver import ArchivePolicy
from mailman.interfaces.handler import IHandler
@@ -43,7 +44,8 @@ class ToArchive:
def process(self, mlist, msg, msgdata):
"""See `IHandler`."""
# Short circuits.
- if msgdata.get('isdigest') or not mlist.archive:
+ if (msgdata.get('isdigest') or
+ mlist.archive_policy == ArchivePolicy.never):
return
# Common practice seems to favor "X-No-Archive: yes". No other value
# for this header seems to make sense, so we'll just test for it's