Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save codersaiful/121cc82af31f5eaabb71bbfda089237f to your computer and use it in GitHub Desktop.
Save codersaiful/121cc82af31f5eaabb71bbfda089237f to your computer and use it in GitHub Desktop.
<?php
add_filter('wqpmb_show_validation',function($bool, $data){
global $product;
if(!is_object($product)) return $bool;
if(is_object($product) && $product->get_type() === 'simple'){
return $bool;
}else{
return false;
}
return $bool;
},10, 2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment