Mark Sapiro pushed to branch master at GNU Mailman / Mailman Core
Commits: a5dc2647 by Mark Sapiro at 2021-07-27T22:40:36-07:00 Translate invitation and (un)subscription confirmation subjects. - - - - - 1fadf213 by Mark Sapiro at 2021-07-28T06:10:32+00:00 Merge branch 'conf' into 'master' Translate invitation and (un)subscription confirmation subjects. Closes #930 See merge request mailman/mailman!898 - - - - - 2 changed files: - src/mailman/app/subscriptions.py - src/mailman/docs/NEWS.rst Changes: ===================================== src/mailman/app/subscriptions.py ===================================== @@ -619,16 +619,17 @@ def _handle_confirmation_needed_events(event, template_name): # This function handles sending the confirmation email to the user # for both subscriptions requiring confirmation and invitations # requiring acceptance. - if template_name.endswith(':invite'): - subject = _('You have been invited to join the ' - '$event.mlist.fqdn_listname mailing list.') - elif template_name.endswith(':unsubscribe'): - subject = _('Your confirmation is needed to leave the ' - '$event.mlist.fqdn_listname mailing list.') - else: - assert(template_name.endswith(':subscribe')) - subject = _('Your confirmation is needed to join the ' - '$event.mlist.fqdn_listname mailing list.') + with _.using(event.mlist.preferred_language.code): + if template_name.endswith(':invite'): + subject = _('You have been invited to join the ' + '$event.mlist.fqdn_listname mailing list.') + elif template_name.endswith(':unsubscribe'): + subject = _('Your confirmation is needed to leave the ' + '$event.mlist.fqdn_listname mailing list.') + else: + assert(template_name.endswith(':subscribe')) + subject = _('Your confirmation is needed to join the ' + '$event.mlist.fqdn_listname mailing list.') confirm_address = event.mlist.confirm_address(event.token) email_address = event.email # Send a verification email to the address. ===================================== src/mailman/docs/NEWS.rst ===================================== @@ -92,6 +92,8 @@ Bugs * DMARC mitigation wrap message now ensures existing cc and reply-to headers are included in the wrapper. (Closes #926) * The tagger handler now stringifies any Header instances. (Closes #928) +* Invitation and (un)subscription confirmation subjects are now translated + to the list's preferred language. (Closes #930) Command line ------------ View it on GitLab: https://gitlab.com/mailman/mailman/-/compare/49b7cd6672ea41b8cc6b6335f50665338385dd9d...1fadf21305920a647c6e552e43449ae4b948bf89 -- View it on GitLab: https://gitlab.com/mailman/mailman/-/compare/49b7cd6672ea41b8cc6b6335f50665338385dd9d...1fadf21305920a647c6e552e43449ae4b948bf89 You're receiving this email because of your account on gitlab.com.
_______________________________________________ Mailman-checkins mailing list -- mailman-checkins@python.org To unsubscribe send an email to mailman-checkins-le...@python.org https://mail.python.org/mailman3/lists/mailman-checkins.python.org/ Member address: arch...@jab.org