Automattic\WooCommerce\Admin\RemoteInboxNotifications

OrRuleProcessor::validate()publicWC 1.0

Validates the rule.

Метод класса: OrRuleProcessor{}

No Hooks.

Return

true|false. Pass/fail.

Usage

$OrRuleProcessor = new OrRuleProcessor();
$OrRuleProcessor->validate( $rule );
$rule(object) (required)
The rule to validate.

Code of OrRuleProcessor::validate() WC 7.1.0

public function validate( $rule ) {
	if ( ! isset( $rule->operands ) || ! is_array( $rule->operands ) ) {
		return false;
	}

	return true;
}