Skip to content

Commit

Permalink
Update login.py
Browse files Browse the repository at this point in the history
  • Loading branch information
DogukanUrker committed Jan 18, 2024
1 parent f4fbb51 commit 1af529c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions routes/login.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
sha256_crypt,
DB_USERS_ROOT,
render_template,
RECAPTCHA_LOGIN,
RECAPTCHA_SITE_KEY,
RECAPTCHA_VERIFY_URL,
RECAPTCHA_SECRET_KEY,
Expand Down Expand Up @@ -57,7 +58,7 @@ def login(direct):
case _:
match sha256_crypt.verify(password, user[3]):
case True:
match RECAPTCHA:
match RECAPTCHA and RECAPTCHA_LOGIN:
case True:
secretResponse = request.form[
"g-recaptcha-response"
Expand All @@ -71,7 +72,7 @@ def login(direct):
"score"
] > 0.5:
case True:
message("2",f"LOGIN | VERIFICATION: {verifyResponse["success"]} | VERIFICATION SCORE: {verifyResponse["score"]}")
message("2",f"LOGIN RECAPTCHA | VERIFICATION: {verifyResponse["success"]} | VERIFICATION SCORE: {verifyResponse["score"]}")
session["userName"] = user[
1
]
Expand Down

0 comments on commit 1af529c

Please sign in to comment.