mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-09 17:45:32 -04:00
remove commented out code
This commit is contained in:
@@ -151,54 +151,6 @@ def sign_in():
|
|||||||
return redirect(redirect_url)
|
return redirect(redirect_url)
|
||||||
return redirect(url_for("main.show_accounts_or_dashboard"))
|
return redirect(url_for("main.show_accounts_or_dashboard"))
|
||||||
|
|
||||||
# form = LoginForm()
|
|
||||||
# current_app.logger.info("Got the login form")
|
|
||||||
# password_reset_url = url_for(".forgot_password", next=request.args.get("next"))
|
|
||||||
|
|
||||||
# if form.validate_on_submit():
|
|
||||||
# user = User.from_email_address_and_password_or_none(
|
|
||||||
# form.email_address.data, form.password.data
|
|
||||||
# )
|
|
||||||
|
|
||||||
# if user:
|
|
||||||
# # add user to session to mark us as in the process of signing the user in
|
|
||||||
# session["user_details"] = {"email": user.email_address, "id": user.id}
|
|
||||||
|
|
||||||
# if user.state == "pending":
|
|
||||||
# return redirect(
|
|
||||||
# url_for("main.resend_email_verification", next=redirect_url)
|
|
||||||
# )
|
|
||||||
|
|
||||||
# if user.is_active:
|
|
||||||
# if session.get("invited_user_id"):
|
|
||||||
# invited_user = InvitedUser.from_session()
|
|
||||||
# if user.email_address.lower() != invited_user.email_address.lower():
|
|
||||||
# flash("You cannot accept an invite for another person.")
|
|
||||||
# session.pop("invited_user_id", None)
|
|
||||||
# abort(403)
|
|
||||||
# else:
|
|
||||||
# invited_user.accept_invite()
|
|
||||||
|
|
||||||
# user.send_login_code()
|
|
||||||
|
|
||||||
# if user.sms_auth:
|
|
||||||
# return redirect(url_for(".two_factor_sms", next=redirect_url))
|
|
||||||
|
|
||||||
# if user.email_auth:
|
|
||||||
# return redirect(
|
|
||||||
# url_for(".two_factor_email_sent", next=redirect_url)
|
|
||||||
# )
|
|
||||||
|
|
||||||
# # Vague error message for login in case of user not known, locked, inactive or password not verified
|
|
||||||
# flash(
|
|
||||||
# Markup(
|
|
||||||
# (
|
|
||||||
# f"The email address or password you entered is incorrect."
|
|
||||||
# f" <a href={password_reset_url} class='usa-link'>Forgot your password?</a>"
|
|
||||||
# )
|
|
||||||
# )
|
|
||||||
# )
|
|
||||||
|
|
||||||
other_device = current_user.logged_in_elsewhere()
|
other_device = current_user.logged_in_elsewhere()
|
||||||
|
|
||||||
token = generate_token(
|
token = generate_token(
|
||||||
@@ -213,10 +165,8 @@ def sign_in():
|
|||||||
url = url.replace("STATE", token)
|
url = url.replace("STATE", token)
|
||||||
return render_template(
|
return render_template(
|
||||||
"views/signin.html",
|
"views/signin.html",
|
||||||
# form=form,
|
|
||||||
again=bool(redirect_url),
|
again=bool(redirect_url),
|
||||||
other_device=other_device,
|
other_device=other_device,
|
||||||
# password_reset_url=password_reset_url,
|
|
||||||
initial_signin_url=url,
|
initial_signin_url=url,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user