Automattic\WooCommerce\Internal\ProductAttributesLookup

DataRegenerator::has_scheduled_action_for_regeneration_step()publicWC 1.0

Check if any pending regeneration step scheduled action exists.

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

Хуков нет.

Возвращает

true|false. True if any pending regeneration step scheduled action exists.

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

$DataRegenerator = new DataRegenerator();
$DataRegenerator->has_scheduled_action_for_regeneration_step(): bool;

Код DataRegenerator::has_scheduled_action_for_regeneration_step() WC 9.3.3

public function has_scheduled_action_for_regeneration_step(): bool {
	$queue   = WC()->get_instance_of( \WC_Queue::class );
	$actions = $queue->search(
		array(
			'hook'   => 'woocommerce_run_product_attribute_lookup_regeneration_callback',
			'status' => \ActionScheduler_Store::STATUS_PENDING,
		),
		'ids'
	);
	return ! empty( $actions );
}