Checking webhook fails when all event types are selected
When webhook is configured with all event types then enabled_events
index contains only *
, not all listed event types.
$webhook = Stripe\WebhookEndpoint Object
(
[id] => we_ASDFQWEQWE
[object] => webhook_endpoint
[api_version] => 2015-07-13
[application] =>
[created] => 1437579495
[enabled_events] => Array
(
[0] => *
)
[livemode] =>
[status] => enabled
[url] => https://www.example.org/civicrm/payment/ipn/1
)
This generates false positive case in checkWebhook($webhook)
method. And in consequence "Problems detected with Stripe webhook https://www.example.org/civicrm/payment/ipn/1 ..." error message on CiviCRM status page