fix: use path only for JsonCacheInfoRepository

JsonCacheInfoRepository assertion requires either path OR databaseName, not both.
Using path only to ensure database is stored in persistent directory.
This commit is contained in:
zarzet
2026-01-19 23:26:10 +07:00
parent 6c8813c9de
commit 8e9d0c3e9a
+2 -2
View File
@@ -51,8 +51,8 @@ class CoverCacheManager {
_cacheKey,
stalePeriod: _maxCacheAge,
maxNrOfCacheObjects: _maxCacheObjects,
// Store database in the same persistent directory
repo: JsonCacheInfoRepository(databaseName: _cacheKey, path: _cachePath),
// Use path only (not databaseName) to store database in persistent directory
repo: JsonCacheInfoRepository(path: _cachePath),
fileSystem: IOFileSystem(_cachePath!),
fileService: HttpFileService(),
),