Merge pull request #7712 from deepeshgarg007/user-fix-develop
fix: Do not send password update notification to disabled users
This commit is contained in:
commit
dc93ff8be3
1 changed files with 1 additions and 1 deletions
|
|
@ -155,7 +155,7 @@ class User(Document):
|
|||
if new_password and not self.flags.in_insert:
|
||||
_update_password(user=self.name, pwd=new_password, logout_all_sessions=self.logout_all_sessions)
|
||||
|
||||
if self.send_password_update_notification:
|
||||
if self.send_password_update_notification and self.enabled:
|
||||
self.password_update_mail(new_password)
|
||||
frappe.msgprint(_("New password emailed"))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue