I currently have a filter in place to disqualify a specific list of coupons for all subscriptions products. I am using this: woocommerce_coupon_is_valid_for_product’, ‘my_function_with_coupons’, 10, 4 );. It works great except it appears that all of the auto-add coupons override this filter and allow the coupon to be added either way. This is a big problem. What can I do to stop this so we can use the auto-add functionality?
This code is designed to disable coupons for products that have subscription options. This needs to override any other coupon rule. These subscription products are created using the official “woocommerce all products for subscriptions” WC plugin.