diff --git a/CHANGELOG.md b/CHANGELOG.md index 2da458f..b13f0f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/). ## Released +## [2.7.24](https://github.com/wuunder/wuunder-webshopplugin-woocommerce/tag/2.7.24) - 2022-04-19 + +### Fixed +- Replaced deprecated WC functions + ## [2.7.23](https://github.com/wuunder/wuunder-webshopplugin-woocommerce/tag/2.7.23) - 2022-04-14 ### Fixed diff --git a/includes/checkout.php b/includes/checkout.php index 6242cc3..1ad1f84 100644 --- a/includes/checkout.php +++ b/includes/checkout.php @@ -148,7 +148,7 @@ function wcwp_get_order_weight($order_id) if (sizeof($items) > 0) { foreach ($items as $item) { // Create the product - $product = $order->get_product_from_item($item); + $product = $item->get_product(); // Set item weight $weight = $product->get_weight(); $weight_unit = get_option('woocommerce_weight_unit'); diff --git a/includes/wcwuunder-create.php b/includes/wcwuunder-create.php index a52d169..786e752 100644 --- a/includes/wcwuunder-create.php +++ b/includes/wcwuunder-create.php @@ -13,7 +13,7 @@ public function __construct() $this->version_obj = array( 'product' => 'Woocommerce extension', 'version' => array( - 'build' => '2.7.23', + 'build' => '2.7.24', 'plugin' => '2.0'), 'platform' => array( 'name' => 'Woocommerce', @@ -493,7 +493,7 @@ public function wcwp_get_order_items($order_id) $images[] = $image[0]; // Create the product - $product = $order->get_product_from_item($item); + $product = $item->get_product(); // Set the variation if (isset($item['variation_id']) && $item['variation_id'] > 0) { diff --git a/woocommerce-wuunder.php b/woocommerce-wuunder.php index 339b916..b3e29ed 100644 --- a/woocommerce-wuunder.php +++ b/woocommerce-wuunder.php @@ -3,7 +3,7 @@ * Plugin Name: Wuunder for-woocommerce * Plugin URI: https://wearewuunder.com/wuunder-voor-webshops/ * Description: Wuunder shipping plugin - * Version: 2.7.23 + * Version: 2.7.24 * Author: Wuunder * Author URI: http://wearewuunder.com */ @@ -57,7 +57,7 @@ class Woocommerce_Wuunder { public static $plugin_path; public static $plugin_basename; - const VERSION = '2.7.23'; + const VERSION = '2.7.24'; public function __construct() {