From 2d5ab7bc6fc0322016122995382b17555aca0f33 Mon Sep 17 00:00:00 2001 From: Navan Chauhan Date: Sun, 6 Jun 2021 15:55:54 +0530 Subject: removed unnecessary else --- app/views/auth.py | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/app/views/auth.py b/app/views/auth.py index 2833479..a0111a8 100644 --- a/app/views/auth.py +++ b/app/views/auth.py @@ -66,8 +66,7 @@ def signin_user(): if user.confirmation: flask_login.login_user(user) return redirect(url_for("user_dashboard")) - else: - flash("Please Confirm Your Email First.") + flash("Please Confirm Your Email First.") else: flash("Incorrect Password") else: @@ -107,11 +106,10 @@ def login_with_google_auth(): if user.login_type == "google": flask_login.login_user(user) return redirect(url_for("user_dashboard")) - else: - flash( - "An account already exists for this email. Please use your password to log in." - ) - return redirect(url_for("signin_user")) + flash( + "An account already exists for this email. Please use your password to log in." + ) + return redirect(url_for("signin_user")) else: return render_template( "message.html", -- cgit v1.2.3