WordPress at Your Fingertips
function is not described

wc_set_notices() WC 2.6.0

Set all notices at once.

No Hooks.

Return

null. Nothing.

Usage

wc_set_notices( $notices );
$notices(array[]) (required)
Array of notices.

Changelog

Since 2.6.0 Introduced.

Code of wc_set_notices() WC 5.6.0

function wc_set_notices( $notices ) {
	if ( ! did_action( 'woocommerce_init' ) ) {
		wc_doing_it_wrong( __FUNCTION__, __( 'This function should not be called before woocommerce_init.', 'woocommerce' ), '2.6' );
		return;
	}

	WC()->session->set( 'wc_notices', $notices );
}