store method
Store the file via your Storage layer.
destPathshould include trailing slash if desired.
Implementation
Future<String> store({String path = '', required String name}) async {
try {
final content = await bytes;
return await Storage.put(path, name, content.toList());
} catch (e) {
throw FileSystemException('Failed to store file as $name: $e');
}
}