From bea94cb9538a55b1376afd42c2ce751efce62cfe Mon Sep 17 00:00:00 2001 From: Mark Sapiro Date: Wed, 26 Jul 2017 08:11:33 -0700 Subject: Ensure all holds/rejects have a reason. --- src/mailman/rules/implicit_dest.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/mailman/rules/implicit_dest.py') diff --git a/src/mailman/rules/implicit_dest.py b/src/mailman/rules/implicit_dest.py index 7e6658d49..26729a86e 100644 --- a/src/mailman/rules/implicit_dest.py +++ b/src/mailman/rules/implicit_dest.py @@ -88,4 +88,9 @@ class ImplicitDestination: if re.match(escaped, recipient, re.IGNORECASE): return False # Nothing matched. + msgdata['moderation_sender'] = msg.sender + with _.defer_translation(): + # This will be translated at the point of use. + msgdata.setdefault('moderation_reasons', []).append( + _('Message has implicit destination')) return True -- cgit v1.2.3-70-g09d2