diff --git a/frappe/core/doctype/user/user.py b/frappe/core/doctype/user/user.py index 8080a35376..967e4d3115 100644 --- a/frappe/core/doctype/user/user.py +++ b/frappe/core/doctype/user/user.py @@ -28,6 +28,8 @@ class User(Document): self.check_enable_disable() self.update_gravatar() self.remove_all_roles_for_guest() + if self.language == "Loading...": + self.language = None def check_enable_disable(self): # do not allow disabling administrator/guest diff --git a/frappe/utils/boilerplate.py b/frappe/utils/boilerplate.py index 85c23a1f48..21c2f06e93 100644 --- a/frappe/utils/boilerplate.py +++ b/frappe/utils/boilerplate.py @@ -192,14 +192,15 @@ app_version = "0.0.1" desktop_template = """from frappe import _ -data = {{ - "{app_title}": {{ - "color": "{app_color}", - "icon": "{app_icon}", - "type": "module", - "label": _("{app_title}") +def get_data(): + return {{ + "{app_title}": {{ + "color": "{app_color}", + "icon": "{app_icon}", + "type": "module", + "label": _("{app_title}") + }} }} -}} """ setup_template = """from setuptools import setup, find_packages