Skip to content
Snippets Groups Projects
Commit 914bcf7f authored by Jamie McClelland's avatar Jamie McClelland
Browse files

ensure webhook data is populated.

parent 643bfa42
Branches
Tags
1 merge request!197ensure webhook data is populated.
......@@ -1329,6 +1329,13 @@ class CRM_Core_Payment_Stripe extends CRM_Core_Payment {
// We don't handle this event
return FALSE;
}
// Populate the data from this webhook.
$rawEventData = str_replace('Stripe\StripeObject JSON: ', '', $webhookEvent['data']);
$eventData = json_decode($rawEventData, TRUE);
$data = StripeObject::constructFrom($eventData);
$handler->setData($data);
// We retrieve/validate/store the webhook data when it is received.
$handler->setVerifyData(FALSE);
$handler->setExceptionMode(FALSE);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment