Automattic\WooCommerce\Internal\ProductAttributesLookup

DataRegenerator::finalize_regeneration()privateWC 1.0

Cleanup/final option setup after the regeneration has been completed.

{} It's a method of the class: DataRegenerator{}

No Hooks.

Return

null. Nothing.

Usage

// private - for code of main (parent) class only
$result = $this->finalize_regeneration( $enable_usage );
$enable_usage(true|false) (required)
Whether the table usage should be enabled or not.

Code of DataRegenerator::finalize_regeneration() WC 7.1.0

private function finalize_regeneration( bool $enable_usage ) {
	delete_option( 'woocommerce_attribute_lookup_last_product_id_to_process' );
	delete_option( 'woocommerce_attribute_lookup_processed_count' );
	update_option( 'woocommerce_attribute_lookup_enabled', $enable_usage ? 'yes' : 'no' );
	$this->data_store->unset_regeneration_in_progress_flag();
}