Remove filter only needs priority
Co-Authored-By: Dragoș Mocrii <dragosmocrii@users.noreply.github.com>
This commit is contained in:
parent
04e51191c4
commit
192fecc0d8
|
@ -593,7 +593,7 @@ function wc_get_product_class( $class = '', $product = null ) {
|
||||||
$filtered = has_filter( 'post_class', 'wc_product_post_class' );
|
$filtered = has_filter( 'post_class', 'wc_product_post_class' );
|
||||||
|
|
||||||
if ( $filtered ) {
|
if ( $filtered ) {
|
||||||
remove_filter( 'post_class', 'wc_product_post_class', 20, 3 );
|
remove_filter( 'post_class', 'wc_product_post_class', 20 );
|
||||||
}
|
}
|
||||||
|
|
||||||
$post_classes = apply_filters( 'post_class', $post_classes, $class, $product->get_id() );
|
$post_classes = apply_filters( 'post_class', $post_classes, $class, $product->get_id() );
|
||||||
|
|
Loading…
Reference in New Issue