Skip to content
Snippets Groups Projects
Commit 296160b6 authored by Pierre Ecarlat's avatar Pierre Ecarlat
Browse files

Revert "Catch error serviceSouscritId"

parent 64f11512
No related branches found
No related tags found
2 merge requests!64Merge dev into main,!59Revert "Catch error serviceSouscritId"
......@@ -75,22 +75,9 @@ function parseContracts(result) {
function parseServiceId(result) {
log('info', 'Parsing serviceId')
const json = JSON.stringify(result)
const contractInfo =
JSON.parse(json)['Envelope']['Body'][
'commanderCollectePublicationMesuresResponse'
]
if (contractInfo !== undefined) {
return contractInfo['serviceSouscritId']
} else {
const errorMessage =
"No serviceSouscritId found, contract hasn't been created properly."
Sentry.captureException(errorMessage, {
tags: {
section: 'parseServiceId',
},
})
throw new Error(errorMessage)
}
return JSON.parse(json)['Envelope']['Body'][
'commanderCollectePublicationMesuresResponse'
]['serviceSouscritId']
}
/**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment