woocommerce_customer_stock_notifications_supported_stock_statuses filter-hookWC 10.2.0

Filter: woocommerce_customer_stock_notifications_supported_stock_statuses

Usage

add_filter( 'woocommerce_customer_stock_notifications_supported_stock_statuses', 'wp_kama_woocommerce_customer_stock_notifications_supported_statuses_filter' );

/**
 * Function for `woocommerce_customer_stock_notifications_supported_stock_statuses` filter-hook.
 * 
 * @param array $stock_statuses Stock statuses.
 *
 * @return array
 */
function wp_kama_woocommerce_customer_stock_notifications_supported_statuses_filter( $stock_statuses ){

	// filter...
	return $stock_statuses;
}
$stock_statuses(array)
Stock statuses.

Changelog

Since 10.2.0 Introduced.

Where the hook is called

Config::get_eligible_stock_statuses()
woocommerce_customer_stock_notifications_supported_stock_statuses
woocommerce/src/Internal/StockNotifications/Config.php 117-123
self::$eligible_stock_statuses = (array) apply_filters(
	'woocommerce_customer_stock_notifications_supported_stock_statuses',
	array(
		ProductStockStatus::IN_STOCK,
		ProductStockStatus::ON_BACKORDER,
	)
);

Where the hook is used in WooCommerce

Usage not found.