Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- function remove_switch_link( $switch_link, $item_id, $item, $subscription ) {
- $product_to_check = 336;
- if( $subscription->has_product( $product_to_check ) ){
- return '';
- }
- return $switch_link;
- }
- add_filter( 'woocommerce_subscriptions_switch_link', 'remove_switch_link', 100, 4 );
Add Comment
Please, Sign In to add comment