summaryrefslogtreecommitdiff
path: root/Mailman/Handlers/ToDigest.py
diff options
context:
space:
mode:
authorbwarsaw2001-07-19 03:34:36 +0000
committerbwarsaw2001-07-19 03:34:36 +0000
commit4b2c4435184edef59082b3c95e3516ada4df2c61 (patch)
tree609877f1724ec8c3639c3c9a76f5d011d9a0b681 /Mailman/Handlers/ToDigest.py
parent900dee75103624544dcd01779018a2f06ad5d95c (diff)
downloadmailman-4b2c4435184edef59082b3c95e3516ada4df2c61.tar.gz
mailman-4b2c4435184edef59082b3c95e3516ada4df2c61.tar.zst
mailman-4b2c4435184edef59082b3c95e3516ada4df2c61.zip
All membership related attribute access should use the MemberAdaptor
API instead, e.g. GetUserOption() -> getMemberOption() GetPreferredLanguage() -> getMemberLanguage() IsMember() -> isMember() GetDigestDeliveryMembers() -> getDigestMemberKeys() ToDigest.py: clear the one_last_digest() dictionary after sending the digest.
Diffstat (limited to 'Mailman/Handlers/ToDigest.py')
-rw-r--r--Mailman/Handlers/ToDigest.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/Mailman/Handlers/ToDigest.py b/Mailman/Handlers/ToDigest.py
index b2a45355e..569ce1f1d 100644
--- a/Mailman/Handlers/ToDigest.py
+++ b/Mailman/Handlers/ToDigest.py
@@ -327,11 +327,19 @@ def send_i18n_digests(mlist, mboxfp):
# Calculate the recipients lists
plainrecips = []
mimerecips = []
- for user in mlist.GetDigestDeliveryMembers():
- if mlist.GetUserOption(user, mm_cfg.DisableMime):
+ drecips = mlist.getDigestMemberKeys() + self.one_last_digest.keys()
+ for user in mlist.getMemberCPAddresses(drecips):
+ if user is None:
+ # It means that someone who toggled off digest delivery
+ # subsequently unsubscribed from the mailing list. Just ignore
+ # them.
+ continue
+ if mlist.getMemberOption(user, mm_cfg.DisableMime):
plainrecips.append(user)
else:
mimerecips.append(user)
+ # Zap this since we're now delivering the last digest to these folks.
+ self.one_last_digest.clear()
# MIME
virginq.enqueue(mimemsg, recips=mimerecips, listname=mlist.internal_name())
# rfc1153