Archive refactor to improve reliability and consistency

This commit is contained in:
Isaac Abadi
2022-06-23 01:10:18 -04:00
parent 314a5047d6
commit 2ba1dc6333
7 changed files with 102 additions and 41 deletions

View File

@@ -101,7 +101,6 @@ let backendPort = null;
let useDefaultDownloadingAgent = null;
let customDownloadingAgent = null;
let allowSubscriptions = null;
let archivePath = path.join(__dirname, 'appdata', 'archives');
// other needed values
let url_domain = null;
@@ -506,7 +505,7 @@ async function loadConfig() {
db_api.database_initialized_bs.next(true);
// creates archive path if missing
await fs.ensureDir(archivePath);
await fs.ensureDir(utils.getArchiveFolder());
// check migrations
await checkMigrations();