deleteFile method

  1. @override
Future<void> deleteFile(
  1. String path
)
override

Deletes the file at the specified path.

Implementation

@override
Future<void> deleteFile(String path) async {
  final file = await getFile(path);
  if (await file.exists()) {
    await file.delete();
  } else {
    throw FileSystemException("File not found: $path");
  }
}