Automattic\WooCommerce\Admin\RemoteInboxNotifications

PublishBeforeTimeRuleProcessor::process()publicWC 1.0

Process the rule.

Method of the class: PublishBeforeTimeRuleProcessor{}

No Hooks.

Return

true|false. Whether the rule passes or not.

Usage

$PublishBeforeTimeRuleProcessor = new PublishBeforeTimeRuleProcessor();
$PublishBeforeTimeRuleProcessor->process( $rule, $stored_state );
$rule(object) (required)
The specific rule being processed by this rule processor.
$stored_state(object) (required)
Stored state.

PublishBeforeTimeRuleProcessor::process() code WC 8.7.0

public function process( $rule, $stored_state ) {
	return $this->date_time_provider->get_now() <= new \DateTime( $rule->publish_before );
}