deleteFile static method

Future deleteFile(
  1. String path
)

删除文件

Implementation

static Future deleteFile(String path) async {
  try {
    if (File(path).existsSync()) {
      await File(path).delete();
    }
  } catch (e, s) {
    LogService.instance.reportError('删除文件', e, s);
  }
}