feat: pre-login hook (#26394)

This commit is contained in:
paurosello 2024-05-13 10:11:06 +02:00 committed by GitHub
parent 49fb60a0dd
commit c19e6a8732
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -125,6 +125,8 @@ class LoginManager:
self.set_user_info()
def login(self):
self.run_trigger("before_login")
if frappe.get_system_settings("disable_user_pass_login"):
frappe.throw(_("Login with username and password is not allowed."), frappe.AuthenticationError)