Update match all books to load items from DB, remove library items loading to memory on init

This commit is contained in:
advplyr 2023-09-04 16:33:55 -05:00
parent 03115e5e53
commit 1dd1fe8994
19 changed files with 127 additions and 140 deletions

View file

@ -8,8 +8,6 @@ const filePerms = require('../utils/filePerms')
class AuthorFinder {
constructor() {
this.AuthorPath = Path.join(global.MetadataPath, 'authors')
this.audnexus = new Audnexus()
}
@ -37,7 +35,7 @@ class AuthorFinder {
}
async saveAuthorImage(authorId, url) {
var authorDir = this.AuthorPath
var authorDir = Path.join(global.MetadataPath, 'authors')
var relAuthorDir = Path.posix.join('/metadata', 'authors')
if (!await fs.pathExists(authorDir)) {
@ -61,4 +59,4 @@ class AuthorFinder {
}
}
}
module.exports = AuthorFinder
module.exports = new AuthorFinder()