wc_is_webhook_valid_status()WC 3.5.3

Check if given status is a valid webhook status.

No Hooks.

Return

true|false.

Usage

wc_is_webhook_valid_status( $status );
$status(string) (required)
Status to check.

Changelog

Since 3.5.3 Introduced.

wc_is_webhook_valid_status() code WC 9.4.2

function wc_is_webhook_valid_status( $status ) {
	return in_array( $status, array_keys( wc_get_webhook_statuses() ), true );
}