Repository Forums Support WooCommerce Extended Coupon Features PRO Free product not showing in cart Reply To: Free product not showing in cart

#4047
Soft79
Keymaster

The issue was the WooCommerce Product Addons plugin. It uses the filter woocommerce_add_cart_item_data and expects an argument that was added in WC 3.3.0. I will add this argument in the next release.

A quick fix would be changing wp-content/plugins/woocommerce-auto-added-coupons-pro/pro/plugins/WJECF_Pro_Free_Products/WJECF_Pro_Free_Products.php line #693:

$cart_item_data = (array) apply_filters( 'woocommerce_add_cart_item_data', $cart_item_data, $product_id, $variation_id );

to:

$cart_item_data = (array) apply_filters( 'woocommerce_add_cart_item_data', $cart_item_data, $product_id, $variation_id, $quantity );