Skip to content

Commit

Permalink
Removing unecessary cast
Browse files Browse the repository at this point in the history
  • Loading branch information
DGoiana committed Mar 8, 2024
1 parent 86915a1 commit ee0fec0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion uni/lib/controller/cleanup.dart
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Future<void> cleanDirectory(Directory directory, DateTime threshold) async {
final entities = directory.listSync(recursive: true, followLinks: false);
final toDeleteEntities = entities.whereType<File>().where((file) {
try {
final fileDate = File(file.path).lastModifiedSync();
final fileDate = file.lastModifiedSync();
return fileDate.isBefore(threshold) && path.extension(file.path) != '.db';
} catch (e) {
return false;
Expand Down

0 comments on commit ee0fec0

Please sign in to comment.