fix issue with database path falling back to faulty path
update logic in welcome wizard, add checks for qapplication instance
This commit is contained in:
@@ -19,6 +19,11 @@ if not os.path.exists(CONFIG_DIR):
|
||||
|
||||
|
||||
settings = Config(f"{CONFIG_DIR}/config.yaml")
|
||||
DATABASE_DIR = (
|
||||
app.user_config_dir if settings.database.path is None else settings.database.path
|
||||
)
|
||||
if not os.path.exists(DATABASE_DIR):
|
||||
os.makedirs(DATABASE_DIR)
|
||||
first_launch = settings.exists
|
||||
if not os.path.exists(settings.database.temp.expanduser()):
|
||||
settings.database.temp.expanduser().mkdir(parents=True, exist_ok=True)
|
||||
|
||||
Reference in New Issue
Block a user