wc_webhook_process_delivery()WC 3.3.0

Process webhook delivery.

Хуков нет.

Возвращает

null. Ничего (null).

Использование

wc_webhook_process_delivery( $webhook, $arg );
$webhook(WC_Webhook) (обязательный)
Webhook instance.
$arg(массив) (обязательный)
Delivery arguments.

Список изменений

С версии 3.3.0 Введена.

Код wc_webhook_process_delivery() WC 8.7.0

function wc_webhook_process_delivery( $webhook, $arg ) {
	// We need to queue the webhook so that it can be ran after the request has finished processing.
	global $wc_queued_webhooks;
	if ( ! isset( $wc_queued_webhooks ) ) {
		$wc_queued_webhooks = array();
	}
	$wc_queued_webhooks[] = array(
		'webhook' => $webhook,
		'arg'     => $arg,
	);
}