readFileAsBytes method
Read a file as bytes. Returns null if file doesn't exist or reading fails.
Implementation
@override
Uint8List? readFileAsBytes(String path) {
try {
final file = io.File(path);
if (file.existsSync()) {
return file.readAsBytesSync();
}
return null;
} catch (_) {
return null;
}
}