Skip to content

Commit

Permalink
Remove translations from admin-* emails
Browse files Browse the repository at this point in the history
On second thought, we probably don't want localization for admin emails.
  • Loading branch information
divbzero committed Apr 15, 2022
1 parent d7d7923 commit bec7058
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 20 deletions.
15 changes: 0 additions & 15 deletions warehouse/locale/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -1292,21 +1292,6 @@ msgid ""
"%(initiator_username)s to a project on %(site)s."
msgstr ""

#: warehouse/templates/email/admin-new-organization-requested/body.html:17
#, python-format
msgid ""
"<a href=\"%(initiator_profile)s\">%(initiator_username)s</a> has "
"requested approval to create a new PyPI organization named "
"\"%(organization_name)s\"."
msgstr ""

#: warehouse/templates/email/admin-new-organization-requested/body.html:19
#, python-format
msgid ""
"Please follow <a href=\"%(approve_organization_link)s\">this link</a> to "
"approve or decline the request."
msgstr ""

#: warehouse/templates/email/basic-auth-with-2fa/body.html:17
#: warehouse/templates/email/password-compromised-hibp/body.html:18
#: warehouse/templates/email/password-compromised/body.html:18
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{% extends "email/_base/body.html" %}

{% block content %}
<p>{% trans organization_name=organization_name, initiator_username=initiator_username, initiator_profile=request.route_url('accounts.profile', username=initiator_username) %}<a href="{{ initiator_profile }}">{{ initiator_username }}</a> has requested approval to create a new PyPI organization named "{{ organization_name }}".{% endtrans %}</p>
<p><a href="{{ request.route_url('accounts.profile', username=initiator_username) }}">{{ initiator_username }}</a> has requested approval to create a new PyPI organization named "{{ organization_name }}".</p>

<p>{% trans approve_organization_link=request.route_url('admin.organization.approve', _query={'organization_name': organization_name}) %}Please follow <a href="{{ approve_organization_link }}">this link</a> to approve or decline the request.{% endtrans %}</p>
<p>Please follow <a href="{{ request.route_url('admin.organization.approve', _query={'organization_name': organization_name}) }}">this link</a> to approve or decline the request.</p>
{% endblock %}
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
{% extends "email/_base/body.txt" %}

{% block content %}
{% trans organization_name=organization_name, initiator_username=initiator_username %}{{ initiator_username }} has requested approval to create a new PyPI organization named "{{ organization_name }}".{% endtrans %}
{{ initiator_username }} has requested approval to create a new PyPI organization named "{{ organization_name }}".

{% trans %}Please follow this link to approve or decline the request:{% endtrans %}
Please follow this link to approve or decline the request:
{{ request.route_url('admin.organization.approve', _query={'organization_name': organization_name}) }}
{% endblock %}
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@

{% extends "email/_base/subject.txt" %}

{% block subject %}{% trans organization_name=organization_name, initiator_username=initiator_username %}{{ initiator_username }} has requested approval to create an organization named "{{ organization_name }}"{% endtrans %}{% endblock %}
{% block subject %}{{ initiator_username }} has requested approval to create an organization named "{{ organization_name }}"{% endblock %}

0 comments on commit bec7058

Please sign in to comment.