diff options
| author | Barry Warsaw | 2011-03-16 15:17:17 -0400 |
|---|---|---|
| committer | Barry Warsaw | 2011-03-16 15:17:17 -0400 |
| commit | 4943fba2eb4d812c20dbae1a61ce5e3b56d9a4d7 (patch) | |
| tree | ef32d56c3721081ea31090a3f249c9b4a01af6a0 /src/mailman/app/moderator.py | |
| parent | 2c562fd0191b0af04511dad2b0d0ae57b31198e7 (diff) | |
| parent | 99c83c30436c5d6e4704374a37a4ad38e0a5a0aa (diff) | |
| download | mailman-4943fba2eb4d812c20dbae1a61ce5e3b56d9a4d7.tar.gz mailman-4943fba2eb4d812c20dbae1a61ce5e3b56d9a4d7.tar.zst mailman-4943fba2eb4d812c20dbae1a61ce5e3b56d9a4d7.zip | |
Diffstat (limited to 'src/mailman/app/moderator.py')
| -rw-r--r-- | src/mailman/app/moderator.py | 40 |
1 files changed, 21 insertions, 19 deletions
diff --git a/src/mailman/app/moderator.py b/src/mailman/app/moderator.py index cdfedd44b..50a03c833 100644 --- a/src/mailman/app/moderator.py +++ b/src/mailman/app/moderator.py @@ -48,6 +48,7 @@ from mailman.interfaces.member import ( AlreadySubscribedError, DeliveryMode, NotAMemberError) from mailman.interfaces.messages import IMessageStore from mailman.interfaces.requests import IRequests, RequestType +from mailman.utilities.i18n import make NL = '\n' @@ -209,12 +210,12 @@ def hold_subscription(mlist, address, realname, password, mode, language): if mlist.admin_immed_notify: subject = _( 'New subscription request to list $mlist.real_name from $address') - text = Utils.maketext( - 'subauth.txt', - {'username' : address, - 'listname' : mlist.fqdn_listname, - 'admindb_url': mlist.script_url('admindb'), - }, mlist=mlist) + text = make('subauth.txt', + mailing_list=mlist, + username=address, + listname=mlist.fqdn_listname, + admindb_url=mlist.script_url('admindb'), + ) # This message should appear to come from the <list>-owner so as # to avoid any useless bounce processing. msg = UserNotification( @@ -281,12 +282,12 @@ def hold_unsubscription(mlist, address): if mlist.admin_immed_notify: subject = _( 'New unsubscription request from $mlist.real_name by $address') - text = Utils.maketext( - 'unsubauth.txt', - {'address' : address, - 'listname' : mlist.fqdn_listname, - 'admindb_url': mlist.script_url('admindb'), - }, mlist=mlist) + text = make('unsubauth.txt', + mailing_list=mlist, + address=address, + listname=mlist.fqdn_listname, + admindb_url=mlist.script_url('admindb'), + ) # This message should appear to come from the <list>-owner so as # to avoid any useless bounce processing. msg = UserNotification( @@ -336,13 +337,14 @@ def _refuse(mlist, request, recip, comment, origmsg=None, lang=None): lang = (mlist.preferred_language if member is None else member.preferred_language) - text = Utils.maketext( - 'refuse.txt', - {'listname' : mlist.fqdn_listname, - 'request' : request, - 'reason' : comment, - 'adminaddr': mlist.owner_address, - }, lang=lang.code, mlist=mlist) + text = make('refuse.txt', + mailing_list=mlist, + language=lang.code, + listname=mlist.fqdn_listname, + request=request, + reason=comment, + adminaddr=mlist.owner_address, + ) with _.using(lang.code): # add in original message, but not wrap/filled if origmsg: |
