getFileFromPath static method
Implementation
static Future<File> getFileFromPath(String filePath) async {
AppConfig.logger.d("Getting File From Path: $filePath");
File file = File("");
try {
AppConfig.logger.i("File Path: $filePath");
if(!kIsWeb && Platform.isAndroid) {
file = File(filePath);
} else {
file = await File.fromUri(Uri.parse(filePath)).create();
}
} catch (e, st) {
NeomErrorLogger.recordError(e, st, module: 'neom_commons', operation: 'getFileFromPath');
}
return file;
}