Delete variations when product type changes to a non-variable product #26959
Labels
priority: normal
The issue/PR is of normal priority—not many people are affected or there’s a workaround, etc.
type: enhancement
The issue is a request for an enhancement.
Is your feature request related to a problem? Please describe.
The issue isn't exactly with WC Core but fixing it here makes more sense as it simply supports what needs to happen in WC Subscriptions by making a minor change in
product_type_changed
function without any side-effects in WC Core.Current function
Proposed changes to the function
The original issue is located in WC Subscriptions: https://github.com/woocommerce/woocommerce-subscriptions/issues/3672 and a potential PR for it is located here: https://github.com/woocommerce/woocommerce-subscriptions/pull/3732.
Describe the solution you'd like
The PR I linked above achieves the following expected behavior:
If this sounds good, I'll make a new PR in WC Core (moving the code from my PR in WC Subscriptions).
Describe alternatives you've considered
Unhooking the
product_type_changed
function in WC Core and re-hooking it in WC Subscriptions as explained in the PR linked above but it makes more sense to do it WC Core.The text was updated successfully, but these errors were encountered: