wc_order_milestone_egg_enabled filter-hookWC 10.9.0

Filters whether the order milestone easter egg feature is enabled.

Return false to disable the feature entirely — no order queries or assets will be loaded.

Usage

add_filter( 'wc_order_milestone_egg_enabled', 'wp_kama_wc_order_milestone_egg_enabled_filter' );

/**
 * Function for `wc_order_milestone_egg_enabled` filter-hook.
 * 
 * @param bool $enabled Whether the feature is enabled.
 *
 * @return bool
 */
function wp_kama_wc_order_milestone_egg_enabled_filter( $enabled ){

	// filter...
	return $enabled;
}
$enabled(true|false)
Whether the feature is enabled.
Default: true

Changelog

Since 10.9.0 Introduced.

Where the hook is called

OrderMilestoneEasterEgg::handle_admin_enqueue_scripts()
wc_order_milestone_egg_enabled
woocommerce/src/Internal/Admin/OrderMilestoneEasterEgg.php 119
if ( ! apply_filters( 'wc_order_milestone_egg_enabled', true ) ) {

Where the hook is used in WooCommerce

Usage not found.