mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-20 14:29:51 -04:00
alter login flow to allow for email auth login
This commit is contained in:
@@ -46,3 +46,17 @@ def check_and_resend_verification_code():
|
||||
return redirect(url_for('main.verify'))
|
||||
else:
|
||||
return redirect(url_for('main.two_factor'))
|
||||
|
||||
|
||||
@main.route('/email-not-received', methods=['GET'])
|
||||
@redirect_to_sign_in
|
||||
def email_not_received():
|
||||
return render_template('views/email-not-received.html')
|
||||
|
||||
|
||||
@main.route('/send-new-email-token', methods=['GET'])
|
||||
@redirect_to_sign_in
|
||||
def resend_email_link():
|
||||
user_api_client.send_verify_code(session['user_details']['id'], 'email', None)
|
||||
session.pop('user_details')
|
||||
return redirect(url_for('main.two_factor_email_sent', email_resent=True))
|
||||
|
||||
Reference in New Issue
Block a user