This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Commit c757f1a
1 parent 32b71c1 commit c757f1a Copy full SHA for c757f1a
File tree 3 files changed +9
-3
lines changed
3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ description: A project that showcases usage of flutter_cache_manager
3
3
publish_to : none
4
4
version : 1.0.0+1
5
5
environment :
6
- sdk : ' >=2.17 .0 <4.0.0'
6
+ sdk : ' >=2.19 .0 <4.0.0'
7
7
8
8
dependencies :
9
9
baseflow_plugin_template : ^2.1.2
Original file line number Diff line number Diff line change 1
1
import 'dart:async' ;
2
+ import 'dart:io' ;
2
3
3
4
import 'package:flutter_cache_manager/flutter_cache_manager.dart' ;
4
5
import 'package:flutter_cache_manager/src/storage/cache_object.dart' ;
@@ -184,7 +185,12 @@ class CacheStore {
184
185
}
185
186
final file = await fileSystem.createFile (cacheObject.relativePath);
186
187
if (await file.exists ()) {
187
- await file.delete ();
188
+ try {
189
+ await file.delete ();
190
+ // ignore: unused_catch_clause
191
+ } on PathNotFoundException catch (e) {
192
+ // File has already been deleted. Do nothing #184
193
+ }
188
194
}
189
195
}
190
196
Original file line number Diff line number Diff line change 6
6
- cache
7
7
- cache-manager
8
8
environment :
9
- sdk : ' >=2.17 .0 <4.0.0'
9
+ sdk : ' >=2.19 .0 <4.0.0'
10
10
11
11
dependencies :
12
12
clock : ^1.1.0
You can’t perform that action at this time.
0 commit comments