From 4fc24fcf4735779df28b3e0dbd255ff8b743d858 Mon Sep 17 00:00:00 2001 From: Jean-Romain Garnier Date: Fri, 17 Apr 2020 15:22:53 +0200 Subject: [PATCH] Use get_full_name to generate confirm_email.html --- users/templates/users/confirm_email.html | 2 +- users/views.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/users/templates/users/confirm_email.html b/users/templates/users/confirm_email.html index 6d562377..60bcf11d 100644 --- a/users/templates/users/confirm_email.html +++ b/users/templates/users/confirm_email.html @@ -33,7 +33,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% csrf_token %}

{% blocktrans %}Confirmation email{% endblocktrans %}

-

{% blocktrans %}Confirm the email{% endblocktrans %} {{ email }} {% blocktrans %}for {{ firstname }} {{ lastname }}.{% endblocktrans %}

+

{% blocktrans %}Confirm the email{% endblocktrans %} {{ email }} {% blocktrans %}for {{ name }}.{% endblocktrans %}

{% trans "Confirm" as tr_confirm %} {% bootstrap_button tr_confirm button_type="submit" icon="ok" button_class="btn-success" %}
diff --git a/users/views.py b/users/views.py index cd135546..19d7d97f 100644 --- a/users/views.py +++ b/users/views.py @@ -1045,7 +1045,7 @@ def process_email(request, req): return redirect(reverse("index")) return form( - {"email": user.email, "firstname": user.name, "lastname": user.surname}, + {"email": user.email, "name": user.get_full_name()}, "users/confirm_email.html", request )