Skip to content

Commit

Permalink
Revert "Add dedicated integration with Product Bundles,"
Browse files Browse the repository at this point in the history
This reverts commit 4cf0e9e.
  • Loading branch information
tomalec committed Jun 16, 2024
1 parent 4cf0e9e commit ce3debc
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions includes/class-wc-abstract-google-analytics-js.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,13 +230,6 @@ 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' ] ) ) {
$price = $product->get_bundle_price( 'min' );
}

$formatted = array(
'id' => $product_id,
'name' => $product->get_title(),
Expand Down

0 comments on commit ce3debc

Please sign in to comment.