fix sentry capture message for webhook

This commit is contained in:
Christophe Robillard 2023-10-10 09:46:28 +02:00
parent dd3805b7cd
commit 73953a8a57
2 changed files with 5 additions and 2 deletions

View file

@ -18,7 +18,7 @@ class WebHookJob < ApplicationJob
if !response.success?
Sentry.set_tags(procedure: procedure_id, dossier: dossier_id)
Sentry.set_extras(web_hook_url: procedure.web_hook_url)
Sentry.capture_message("Webhook error: #{response.status} // Response: #{response.body}")
Sentry.capture_message("Webhook error code: #{response.code} (#{response.return_message}) // Response: #{response.body}")
end
end
end