mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-19 05:59:44 -04:00
Turn on redirects for new_password
This is part of the work to make sure user is redirected to the page they initially were meant to visit after they sign in.
This commit is contained in:
@@ -5,6 +5,7 @@ from flask import (
|
||||
flash,
|
||||
redirect,
|
||||
render_template,
|
||||
request,
|
||||
session,
|
||||
url_for,
|
||||
)
|
||||
@@ -46,6 +47,6 @@ def new_password(token):
|
||||
else:
|
||||
# send user a 2fa sms code
|
||||
user.send_verify_code()
|
||||
return redirect(url_for('main.two_factor'))
|
||||
return redirect(url_for('main.two_factor', next=request.args.get('next')))
|
||||
else:
|
||||
return render_template('views/new-password.html', token=token, form=form, user=user)
|
||||
|
||||
Reference in New Issue
Block a user