Automattic\WooCommerce\Admin\RemoteInboxNotifications

ProductCountRuleProcessor::__construct()publicWC 1.0

Constructor.

Method of the class: ProductCountRuleProcessor{}

No Hooks.

Return

null. Nothing.

Usage

$ProductCountRuleProcessor = new ProductCountRuleProcessor();
$ProductCountRuleProcessor->__construct( $product_query );
$product_query(object)
The product query.
Default: null

ProductCountRuleProcessor::__construct() code WC 7.1.0

public function __construct( $product_query = null ) {
	$this->product_query = null === $product_query
		? new \WC_Product_Query(
			array(
				'limit'    => 1,
				'paginate' => true,
				'return'   => 'ids',
				'status'   => array( 'publish' ),
			)
		)
		: $product_query;
}