I was trying to use AWS SDK for JS to perform a multipart upload in a web worker. When i initiate a createMultipartUpload, I am able to see the uploadID in api call for incomplete multipart upload. But the createMultipartUpload is not returning the upload ID. Can we use the AWS SDK for JS on the web worker? and if so am I doing anything wrong here?
Code:
a=s3.createMultipartUpload(params, function (err, data) {
//Execution doesn't reach here
console.log(data);
if (err) {
console.log(err, err.stack); // an error occurred
} else {
uploadId = data.UploadId
}
});