This commit is contained in:
Khanh Ngo 2018-04-01 15:51:56 +07:00
parent 6fa8ae37f0
commit 3efafecb30

View File

@ -73,6 +73,9 @@ def inject_default_domain_table_size_setting():
@app.context_processor
def inject_auto_ptr_setting():
auto_ptr_setting = Setting.query.filter(Setting.name == 'auto_ptr').first()
if auto_ptr_setting is None:
return dict(auto_ptr_setting=False)
else:
return dict(auto_ptr_setting=strtobool(auto_ptr_setting.value))