mirror of
https://github.com/bunkerity/bunkerweb
synced 2026-05-24 09:28:37 +00:00
Remove unnecessary check fields in global_config() function
This commit is contained in:
parent
da8a40d18b
commit
30a4155127
1 changed files with 5 additions and 1 deletions
|
|
@ -820,12 +820,16 @@ def global_config():
|
|||
# Edit check fields and remove already existing ones
|
||||
config = app.config["CONFIG"].get_config(methods=False)
|
||||
for variable, value in deepcopy(variables).items():
|
||||
if variable.endswith("SCHEMA"):
|
||||
del variables[variable]
|
||||
continue
|
||||
|
||||
if value == "on":
|
||||
value = "yes"
|
||||
elif value == "off":
|
||||
value = "no"
|
||||
|
||||
if value == config.get(variable, None) or not value.strip():
|
||||
if value == config.get(variable, None):
|
||||
del variables[variable]
|
||||
|
||||
if not variables:
|
||||
|
|
|
|||
Loading…
Reference in a new issue