Automattic\WooCommerce\Internal\Admin\BlockTemplates
AbstractBlockTemplate::uncache_block()
Uncaches a block in the template. This is an internal method and should not be called directly except for from the BlockContainerTrait's remove_block() method.
Method of the class: AbstractBlockTemplate{}
No Hooks.
Return
null
. Nothing (null).
Usage
$AbstractBlockTemplate = new AbstractBlockTemplate(); $AbstractBlockTemplate->uncache_block( $block_id );
- $block_id(string) (required)
- The block ID.
AbstractBlockTemplate::uncache_block() AbstractBlockTemplate::uncache block code WC 9.3.3
public function uncache_block( string $block_id ) { if ( isset( $this->block_cache[ $block_id ] ) ) { unset( $this->block_cache[ $block_id ] ); } }