Automattic\WooCommerce\Blocks\Domain\Services
Hydration::cache_store_notices
Cache notices before hydrating the API if the customer has a session.
Method of the class: Hydration{}
No Hooks.
Returns
null. Nothing (null).
Usage
// protected - for code of main (parent) or child class $result = $this->cache_store_notices();
Hydration::cache_store_notices() Hydration::cache store notices code WC 10.7.0
protected function cache_store_notices() {
if ( ! did_action( 'woocommerce_init' ) || null === WC()->session ) {
return;
}
$this->cached_store_notices = wc_get_notices();
wc_clear_notices();
}