fix: 清除缓存提示 issues #619

This commit is contained in:
guozhigq
2024-03-08 23:09:52 +08:00
parent 3bf6136bc6
commit a3e1fd4e91
2 changed files with 2 additions and 5 deletions

View File

@ -201,7 +201,6 @@ class _AboutPageState extends State<AboutPage> {
var cleanStatus = await CacheManage().clearCacheAll(); var cleanStatus = await CacheManage().clearCacheAll();
if (cleanStatus) { if (cleanStatus) {
getCacheSize(); getCacheSize();
SmartDialog.showToast('清除成功');
} }
}, },
title: const Text('清除缓存'), title: const Text('清除缓存'),

View File

@ -99,11 +99,9 @@ class CacheManage {
try { try {
// 清除缓存 图片缓存 // 清除缓存 图片缓存
await clearLibraryCache(); await clearLibraryCache();
Timer(const Duration(milliseconds: 500), () {
SmartDialog.dismiss().then((res) { SmartDialog.dismiss().then((res) {
SmartDialog.showToast('清除完成'); SmartDialog.showToast('清除完成');
}); });
});
} catch (err) { } catch (err) {
SmartDialog.dismiss(); SmartDialog.dismiss();
SmartDialog.showToast(err.toString()); SmartDialog.showToast(err.toString());