fix: catch rejected promise if it is in a try-catch block
This commit is contained in:
@ -95,7 +95,7 @@ const uploadToSignedUrl = async (
|
||||
responseType: 'stream',
|
||||
timeout: REQUEST_TIMEOUT,
|
||||
})
|
||||
return axios.put(uploadSignedUrl, stream.data, {
|
||||
return await axios.put(uploadSignedUrl, stream.data, {
|
||||
headers: {
|
||||
'Content-Type': contentType,
|
||||
},
|
||||
|
||||
@ -112,7 +112,7 @@ const createHttpTaskWithToken = async ({
|
||||
}
|
||||
|
||||
try {
|
||||
return client.createTask({ parent, task })
|
||||
return await client.createTask({ parent, task })
|
||||
} catch (error) {
|
||||
logError(error)
|
||||
return null
|
||||
|
||||
Reference in New Issue
Block a user