ensureBytesLoaded method
Implementation
Future<AppFile> ensureBytesLoaded() async {
if (hasBytes || xFile == null || isRemote) {
return this;
}
final bytes = await xFile!.readAsBytes();
return copyWith(
fileBytes: bytes,
size: size ?? bytes.lengthInBytes,
);
}