From d9f5819ff345690274cd4154a42bd1f8671d2071 Mon Sep 17 00:00:00 2001 From: bwarsaw Date: Tue, 15 Oct 2002 05:46:54 +0000 Subject: ForwardMessage(): Change the signature a bit to use the new OwnerNotification class in Message.py. We don't need the recips argument since we're always going to calculate that from self's owners and moderators (if the tomoderators flag is true). --- Mailman/Deliverer.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'Mailman/Deliverer.py') diff --git a/Mailman/Deliverer.py b/Mailman/Deliverer.py index 5b2447003..96db58cfa 100644 --- a/Mailman/Deliverer.py +++ b/Mailman/Deliverer.py @@ -119,11 +119,8 @@ your membership administrative address, %(addr)s.''')) msg['X-No-Archive'] = 'yes' msg.send(self) - def ForwardMessage(self, msg, recips=None, text=None, subject=None): + def ForwardMessage(self, msg, text=None, subject=None, tomoderators=1): # Wrap the message as an attachment - if recips is None: - recips = self.owner[:] - recips.extend(self.moderator) if text is None: text = _('No reason given') if subject is None: @@ -131,9 +128,11 @@ your membership administrative address, %(addr)s.''')) text = MIMEText(Utils.wrap(text), _charset=Utils.GetCharSet(self.preferred_language)) attachment = MIMEMessage(msg) - notice = Message.UserNotification( - recips, self.GetBouncesEmail(), subject, - lang=self.preferred_language) + notice = Message.OwnerNotification( + self, self.GetBouncesEmail(), subject, + lang=self.preferred_language, + tomoderators=tomoderators) + # Make it look like the message is going to the -owner address notice.set_type('multipart/mixed') notice.attach(text) notice.attach(attachment) -- cgit v1.2.3-70-g09d2