Skip to content

Commit

Permalink
dont propagate axios error upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
pofider committed Apr 17, 2023
1 parent aa3f7bc commit a16daf6
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions packages/jsreport-docker-workers/lib/sendToWorker.js
Expand Up @@ -76,7 +76,6 @@ async function _sendToWorker (url, _data, { executeMain, timeout, originUrl, sys
isDone = true
if (!err.response?.data) {
const error = new Error('Error when communicating with worker: ' + err.message)
Object.assign(error, { ...err })
error.needRestart = true
throw error
}
Expand All @@ -88,7 +87,6 @@ async function _sendToWorker (url, _data, { executeMain, timeout, originUrl, sys
Object.assign(workerError, errorData)
} catch (e) {
const error = new Error('Error when communicating with worker: ' + err.response.data)
Object.assign(error, { ...e })
error.needRestart = true
throw error
}
Expand Down

0 comments on commit a16daf6

Please sign in to comment.