uploadFileById method

  1. @override
Future<String> uploadFileById({
  1. required String localPath,
  2. required String fileId,
  3. Map<String, dynamic>? metadata,
})
override

Uploads a file to the cloud storage.

Implementation

@override
Future<String> uploadFileById(
    {required String localPath,
    required String fileId,
    Map<String, dynamic>? metadata}) async {
  _checkAuth();

  var folderInfo = await _findOrJoinSharedFolder(fileId);
  final remoteFilePath = "${folderInfo['path_lower']}/sync_file.json";

  debugPrint("Uploading to resolved remote path: $remoteFilePath");
  return uploadFile(
      localPath: localPath, remotePath: remoteFilePath, metadata: metadata);
}