diff options
| author | Barry Warsaw | 2015-01-04 20:20:33 -0500 |
|---|---|---|
| committer | Barry Warsaw | 2015-01-04 20:20:33 -0500 |
| commit | 4a612db8e89afed74173b93f3b64fa567b8417a3 (patch) | |
| tree | 81a687d113079a25f93279f35c7eee2aa2572510 /src/mailman/handlers/to_digest.py | |
| parent | 84af79988a4e916604cba31843778206efb7d1b8 (diff) | |
| parent | de181c1a40965a3a7deedd56a034a946f45b6984 (diff) | |
| download | mailman-4a612db8e89afed74173b93f3b64fa567b8417a3.tar.gz mailman-4a612db8e89afed74173b93f3b64fa567b8417a3.tar.zst mailman-4a612db8e89afed74173b93f3b64fa567b8417a3.zip | |
Diffstat (limited to 'src/mailman/handlers/to_digest.py')
| -rw-r--r-- | src/mailman/handlers/to_digest.py | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/mailman/handlers/to_digest.py b/src/mailman/handlers/to_digest.py index e915bbfa3..70aeb0dcc 100644 --- a/src/mailman/handlers/to_digest.py +++ b/src/mailman/handlers/to_digest.py @@ -17,9 +17,6 @@ """Add the message to the list's current digest.""" -from __future__ import absolute_import, print_function, unicode_literals - -__metaclass__ = type __all__ = [ 'ToDigest', ] @@ -27,8 +24,6 @@ __all__ = [ import os -from zope.interface import implementer - from mailman.config import config from mailman.core.i18n import _ from mailman.email.message import Message @@ -36,6 +31,7 @@ from mailman.interfaces.digests import DigestFrequency from mailman.interfaces.handler import IHandler from mailman.utilities.datetime import now as right_now from mailman.utilities.mailbox import Mailbox +from zope.interface import implementer @@ -55,7 +51,7 @@ class ToDigest: mailbox_path = os.path.join(mlist.data_path, 'digest.mmdf') # Lock the mailbox and append the message. with Mailbox(mailbox_path, create=True) as mbox: - mbox.add(msg.as_string()) + mbox.add(msg) # Calculate the current size of the mailbox file. This will not tell # us exactly how big the resulting MIME and rfc1153 digest will # actually be, but it's the most easily available metric to decide @@ -75,7 +71,7 @@ class ToDigest: os.rename(mailbox_path, mailbox_dest) config.switchboards['digest'].enqueue( Message(), - listname=mlist.fqdn_listname, + listid=mlist.list_id, digest_path=mailbox_dest, volume=volume, digest_number=digest_number) |
