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

Merge branch 'revert-64f11512' into 'dev'

Revert "Catch error serviceSouscritId"

See merge request !59
parents 64f11512 296160b6
No related branches found
No related tags found
2 merge requests!64Merge dev into main,!59Revert "Catch error serviceSouscritId"
Pipeline #105129 passed
......@@ -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