Override check_cart_item_stock function
-
Hi,
I’m looking for a solution to override the check_cart_item_stock() function in the class-wc-cart.php file.
My shop have products with many variations.
If a user have the same product in the cart, but with 4 or 5 different variations, if there is an out-of-stock error message, having just the name is too ambiguous for user.
I’d like to return something like :
Sorry, we do not have enough "%1$s - Women, Blue, S" in stock
To resume, I’d like to add the product attribute list in the out of stock error message.
This function doesn’t have any filter to do it.
Could you help me to find the solution ?
Thank you.
Anthony
Viewing 10 replies - 1 through 10 (of 10 total)
Viewing 10 replies - 1 through 10 (of 10 total)
- The topic ‘Override check_cart_item_stock function’ is closed to new replies.