woocommerce_store_api_product_quantity_
woocommerce_store_api_product_quantity_
Appears in: woocommerce.10.1.2
Hook Type: filter
Displaying hooks found in version: woocommerce.10.1.2apply_filters('woocommerce_store_api_product_quantity_') is found 2 times:
- /src/StoreApi/Utilities/QuantityLimits.php line 256
* @param \WC_Product $product The product object. * @param array|null $cart_item The cart item if the product exists in the cart, or null. * @return mixed */ $filtered_value = apply_filters( 'woocommerce_store_api_product_quantity_' . $value_type, $value, $product, $cart_item ); return wc_stock_amount( NumberUtil::normalize( $filtered_value, $value ) ); } /** * Get a boolean value while running it through a filter hook.
- /src/StoreApi/Utilities/QuantityLimits.php line 284
Warning: Undefined array key 288 in /home/c6974294/public_html/wp-plugin-api.com/wp-content/themes/wordpress-hooks/functions.php on line 167
Warning: Undefined array key 289 in /home/c6974294/public_html/wp-plugin-api.com/wp-content/themes/wordpress-hooks/functions.php on line 167
* @param \WC_Product $product The product object. * @param array|null $cart_item The cart item if the product exists in the cart, or null. * @return mixed */ $filtered_value = apply_filters( 'woocommerce_store_api_product_quantity_' . $value_type, $value, $product, $cart_item ); return is_bool( $filtered_value ) ? $filtered_value : (bool) $value; } }