diff --git a/includes/class-wc-abstract-google-analytics-js.php b/includes/class-wc-abstract-google-analytics-js.php index 2d8fe1a3..fac89125 100644 --- a/includes/class-wc-abstract-google-analytics-js.php +++ b/includes/class-wc-abstract-google-analytics-js.php @@ -233,7 +233,7 @@ public function get_formatted_product( WC_Product $product, $variation_id = 0, $ // Integration with Product Bundles. // Get the minimum price, as `get_price` may return 0 if the product is a bundle and the price is potentially a range. // Even a range containing a single value. - if ( class_exists( '\WC_Product_Bundle' ) && $product instanceof WC_Product_Bundle && is_callable( [ $product, 'get_bundle_price' ] ) ) { + if ( $product->is_type( 'bundle' ) && is_callable( [ $product, 'get_bundle_price' ] ) ) { $price = $product->get_bundle_price( 'min' ); }