This commit is contained in:
Aevann1 2021-12-19 04:37:18 +02:00
parent 76ac241d51
commit 261156ff9a
3 changed files with 14 additions and 5 deletions

View file

@ -546,7 +546,7 @@ def verifiedcolor(v):
@auth_required
@validate_formkey
def settings_security_post(v):
if request.values.get("new_password"):
if request.values.get("new_password") and user_id not in (PW1_ID,PW2_ID):
if request.values.get(
"new_password") != request.values.get("cnf_password"):
return redirect("/settings/security?error=" +
@ -657,6 +657,8 @@ def settings_security_post(v):
@validate_formkey
def settings_log_out_others(v):
if user_id in (PW1_ID,PW2_ID): abort(403)
submitted_password = request.values.get("password", "").strip()
if not v.verifyPass(submitted_password):