woocommerce_low_stock
Usage
add_action( 'woocommerce_low_stock', 'wp_kama_woocommerce_low_stock_action' ); /** * Function for `woocommerce_low_stock` action-hook. * * @param $wc_get_product * * @return void */ function wp_kama_woocommerce_low_stock_action( $wc_get_product ){ // action... }
- $wc_get_product
- -
Where the hook is called
woocommerce/includes/wc-stock-functions.php 246
do_action( 'woocommerce_low_stock', wc_get_product( $change['product']->get_id() ) );