Skip to content

Commit

Permalink
small update
Browse files Browse the repository at this point in the history
  • Loading branch information
Your Name committed Jul 30, 2020
1 parent 2e9a439 commit fe6eebd
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions models/db.py
Original file line number Diff line number Diff line change
Expand Up @@ -597,11 +597,13 @@ def widget(**kwargs):
ssl_session_cache shared:SSL6:16m;
}
"""
if db(db.basic_conf.modsec3_data_conf).isempty():
db.basic_conf.update_or_insert(db.basic_conf.id == 1, modsec3_default_config=modsec3_default_config)
try:
if db(db.basic_conf.modsec3_data_conf).isempty():
db.basic_conf.update_or_insert(db.basic_conf.id == 1, modsec3_data_conf=modsec3_default_config)


if db(db.basic_conf.nginx_data_conf).isempty():
db.basic_conf.update_or_insert(db.basic_conf.id == 1, nginx_default_conf=nginx_default_conf)

if db(db.basic_conf.nginx_data_conf).isempty():
db.basic_conf.update_or_insert(db.basic_conf.id == 1, nginx_data_conf=nginx_default_conf)
except:
pass

0 comments on commit fe6eebd

Please sign in to comment.