Signed-off-by: dom <githubaccount56556@proton.me>
This commit is contained in:
dom
2026-05-06 14:14:19 +08:00
parent 1a8c348af1
commit 07843a5e77
239 changed files with 3175 additions and 13237 deletions

View File

@@ -77,15 +77,11 @@ abstract final class CacheManager {
}
static Future<void> autoClearCache() async {
if (Pref.autoClearCache) {
await clearLibraryCache();
} else {
final maxCacheSize = Pref.maxCacheSize;
if (maxCacheSize != 0) {
final currCache = await loadApplicationCache(maxCacheSize);
if (currCache >= maxCacheSize) {
await clearLibraryCache();
}
final maxCacheSize = Pref.maxCacheSize;
if (maxCacheSize != 0) {
final currCache = await loadApplicationCache(maxCacheSize);
if (currCache >= maxCacheSize) {
await clearLibraryCache();
}
}
}