Quellcode durchsuchen

fix: accept path instead of fn in signup hook

version-14
Jannat Patel vor 3 Jahren
Ursprung
Commit
fa4bccb284
1 geänderte Dateien mit 2 neuen und 4 gelöschten Zeilen
  1. +2
    -4
      frappe/www/login.py

+ 2
- 4
frappe/www/login.py Datei anzeigen

@@ -41,10 +41,8 @@ def get_context(context):
frappe.get_system_settings("app_name") or _("Frappe")) frappe.get_system_settings("app_name") or _("Frappe"))


custom_signup = frappe.get_hooks("custom_signup_form") custom_signup = frappe.get_hooks("custom_signup_form")
if custom_signup:
path = frappe.get_attr(custom_signup[0])()
if path:
context["custom_signup_form"] = frappe.get_template(path).render()
if custom_signup and len(custom_signup) and custom_signup[0]:
context["custom_signup_form"] = frappe.get_template(custom_signup[0]).render()


providers = [i.name for i in frappe.get_all("Social Login Key", filters={"enable_social_login":1}, order_by="name")] providers = [i.name for i in frappe.get_all("Social Login Key", filters={"enable_social_login":1}, order_by="name")]
for provider in providers: for provider in providers:


Laden…
Abbrechen
Speichern