diff --git a/lib/services/github_api.dart b/lib/services/github_api.dart index 03eacf8b..8d3244b3 100644 --- a/lib/services/github_api.dart +++ b/lib/services/github_api.dart @@ -38,7 +38,6 @@ class GithubAPI { Future clearAllCache() async { try { await _cacheOptions.store!.clean(); - await DefaultCacheManager().emptyCache(); } on Exception catch (e) { if (kDebugMode) { print(e); diff --git a/lib/services/revanced_api.dart b/lib/services/revanced_api.dart index f21e6b71..fca17c0e 100644 --- a/lib/services/revanced_api.dart +++ b/lib/services/revanced_api.dart @@ -41,7 +41,6 @@ class RevancedAPI { Future clearAllCache() async { try { await _cacheOptions.store!.clean(); - await DefaultCacheManager().emptyCache(); } on Exception catch (e) { if (kDebugMode) { print(e); diff --git a/lib/ui/views/home/home_viewmodel.dart b/lib/ui/views/home/home_viewmodel.dart index 40cf85b4..1ab8437d 100644 --- a/lib/ui/views/home/home_viewmodel.dart +++ b/lib/ui/views/home/home_viewmodel.dart @@ -464,11 +464,7 @@ class HomeViewModel extends BaseViewModel { } Future forceRefresh(BuildContext context) async { - await Future.delayed(const Duration(seconds: 1)); - if (_lastUpdate == null || - _lastUpdate!.difference(DateTime.now()).inSeconds > 2) { - _managerAPI.clearAllData(); - } + _managerAPI.clearAllData(); _toast.showBottom('homeView.refreshSuccess'); initialize(context); }