From 1cb7628d8b9563369ae44c23c66cbffe357daff8 Mon Sep 17 00:00:00 2001 From: Matjaz Gregoric Date: Tue, 1 Apr 2014 09:25:45 +0200 Subject: [PATCH] Don't hardcode https protocol in password reset email. Use http or https, depending on the value of `is_secure`. This is similar to how links in some other email templates work. --- lms/templates/registration/password_reset_email.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lms/templates/registration/password_reset_email.html b/lms/templates/registration/password_reset_email.html index 2ede792e69..e7bbc6cf35 100644 --- a/lms/templates/registration/password_reset_email.html +++ b/lms/templates/registration/password_reset_email.html @@ -3,7 +3,7 @@ {% trans "Please go to the following page and choose a new password:" %} {% block reset_link %} -https://{{domain}}{% url 'student.views.password_reset_confirm_wrapper' uidb36=uid token=token %} +http{% if is_secure %}s{% endif %}://{{domain}}{% url 'student.views.password_reset_confirm_wrapper' uidb36=uid token=token %} {% endblock %} {% trans "If you didn't request this change, you can disregard this email - we have not yet reset your password." %}