mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Fix security
This commit is contained in:
parent
4f4ec16a9b
commit
5d3dbc6f9c
@ -898,11 +898,12 @@ class PanelHandler(BaseHandler):
|
||||
template = "panel/panel_config.html"
|
||||
|
||||
elif page == "config_json":
|
||||
with open(self.helper.settings_file, "r", encoding="utf-8") as f:
|
||||
data = json.load(f)
|
||||
page_data["config-json"] = data
|
||||
if exec_user["superuser"]:
|
||||
with open(self.helper.settings_file, "r", encoding="utf-8") as f:
|
||||
data = json.load(f)
|
||||
page_data["config-json"] = data
|
||||
|
||||
template = "panel/config_json.html"
|
||||
template = "panel/config_json.html"
|
||||
|
||||
elif page == "add_user":
|
||||
page_data["new_user"] = True
|
||||
|
Loading…
Reference in New Issue
Block a user