Automattic\WooCommerce\Admin\RemoteInboxNotifications

IsEcommerceRuleProcessor::process()publicWC 1.0

Passes (or fails) based on whether the site is on the eCommerce plan or not.

{} Это метод класса: IsEcommerceRuleProcessor{}

Хуков нет.

Возвращает

true|false. The result of the operation.

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

$IsEcommerceRuleProcessor = new IsEcommerceRuleProcessor();
$IsEcommerceRuleProcessor->process( $rule, $stored_state );
$rule(объект) (обязательный)
The rule being processed by this rule processor.
$stored_state(объект) (обязательный)
Stored state.

Код IsEcommerceRuleProcessor::process() WC 6.5.1

public function process( $rule, $stored_state ) {
	if ( ! function_exists( 'wc_calypso_bridge_is_ecommerce_plan' ) ) {
		return false === $rule->value;
	}

	return (bool) wc_calypso_bridge_is_ecommerce_plan() === $rule->value;
}