Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-09-05 20:55:52 +08:00
parent 224bd88473
commit 5bf09b98f4
15 changed files with 401 additions and 340 deletions

View File

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