upload method

Future<QBFile?> upload(
  1. String url, {
  2. bool public = false,
})

Implementation

Future<QBFile?> upload(String url, {bool public = false}) async {
  Map<String, Object> data = Map();

  data["url"] = url;
  data["public"] = public;

  Map<Object?, Object?> map =
      await _fileModule.invokeMethod(UPLOAD_METHOD, data);
  QBFile? file = QBFileMapper.mapToQBFile(map);
  return file;
}