fix: reset reset_password_key on password update using link (#9421)
extension to #8982 Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
This commit is contained in:
parent
85ee4f1a67
commit
45e69c9723
1 changed files with 2 additions and 2 deletions
|
|
@ -564,8 +564,8 @@ def update_password(new_password, logout_all_sessions=0, key=None, old_password=
|
|||
|
||||
frappe.local.login_manager.login_as(user)
|
||||
|
||||
frappe.db.set_value("User", user,
|
||||
'last_password_reset_date', today())
|
||||
frappe.db.set_value("User", user, "last_password_reset_date", today())
|
||||
frappe.db.set_value("User", user, "reset_password_key", "")
|
||||
|
||||
if user_doc.user_type == "System User":
|
||||
return "/desk"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue