Skip to content

Commit 13f78d2

Browse files
authored
Create db if missing (#356) (#357)
1 parent 7b97e9e commit 13f78d2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

gramps_webapi/app.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,9 @@ def create_app(config: Optional[Dict[str, Any]] = None):
107107
if not app.config.get(option):
108108
raise ValueError(f"{option} must be specified")
109109

110+
# create database if missing
111+
WebDbManager(name=app.config["TREE"], create_if_missing=True)
112+
110113
# load JWT default settings
111114
app.config.from_object(DefaultConfigJWT)
112115

0 commit comments

Comments
 (0)