Automattic\WooCommerce\Internal\Caches

ProductTransientsDeferrer::start_deferringpublicWC 1.0

Start deferring product transient deletions. Calls can be nested.

Method of the class: ProductTransientsDeferrer{}

No Hooks.

Returns

void. Nothing (null).

Usage

$ProductTransientsDeferrer = new ProductTransientsDeferrer();
$ProductTransientsDeferrer->start_deferring(): void;

ProductTransientsDeferrer::start_deferring() code WC 11.1.1

public function start_deferring(): void {
	++$this->deferral_level;
	if ( 1 === $this->deferral_level ) {
		add_action( 'shutdown', array( $this, 'handle_shutdown' ), self::SHUTDOWN_HOOK_PRIORITY );
	}
}