Skip to content
Snippets Groups Projects
Commit 8c4ed443 authored by Christian Dresen's avatar Christian Dresen
Browse files

[Warpauth] Changed password reset url in /account/

parent d7f52fea
No related branches found
No related tags found
No related merge requests found
......@@ -51,7 +51,7 @@
{% include "two_factor/_wizard_actions.html" %}
</form>
</div>
<a class="btn" href="/reset_password">{% trans "Forgot Password?" %}</a><br>
<a class="btn" href="/account/reset_password">{% trans "Forgot Password?" %}</a><br>
<a class="btn" href="/account/registration/">{% trans "Register" %}</a><br>
<a class="btn" href="/account/registration/resend">{% trans "Resend Activation Link" %}</a>
{% endblock %}
\ No newline at end of file
......@@ -14,8 +14,8 @@ urlpatterns = [
url(r'^account/registration/activate/(?P<token>\w+)/$', register.activate, name='activate'),
url(r'^account/registration/resend/$', register.resend_token, name='resend_token'),
url(r'^reset_password/$', reset_password.gen_token, name='reset_password'),
url(r'^reset_password/(?P<reset_hash>\w+)/$', reset_password.change_password, name='index'),
url(r'^/account/reset_password/$', reset_password.gen_token, name='reset_password'),
url(r'^/account/reset_password/(?P<reset_hash>\w+)/$', reset_password.change_password, name='index'),
url(r'^profile/$', profile.index, name='index'),
url(r'^profile/change_password/$', profile.change_password, name='change_password'),
......
......@@ -32,7 +32,7 @@ def gen_token(request):
p.email = usr.email
p.hash = hashlib.sha1(os.urandom(128)).hexdigest()
p.save()
email_content = _("https://infra.warpzone.ms/reset_password/%(hash)s") % {'hash': p.hash}
email_content = _("https://infra.warpzone.ms/account/reset_password/%(hash)s") % {'hash': p.hash}
ret = send_email(p.email, "Requested Password Reset", email_content )
if not ret:
pages["error"] = "Error while sending the email. Please contact the administrator."
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment