diff --git a/README.txt b/README.txt index c0c2c25..60738b7 100644 --- a/README.txt +++ b/README.txt @@ -4,7 +4,7 @@ Donate link: https://www.udesly.com/ Tags: webflow to wordpress, editor, page builder, layout design, udesly, webflow Requires at least: 5.0 Tested up to: 5.2.3 -Stable tag: 2.0.19 +Stable tag: 2.0.20 License: GPLv3 or later License URI: https://www.udesly.com/terms-conditions-of-use/#udesly-wordpress-plugin Requires PHP: 7.0.0 diff --git a/includes/WC/WC.php b/includes/WC/WC.php index 0eb23c8..ebf5609 100644 --- a/includes/WC/WC.php +++ b/includes/WC/WC.php @@ -29,6 +29,7 @@ public static function public_hooks() add_action('wp_ajax_nopriv_udesly_wc_get_notices', array(self::class, "udesly_wc_get_notices")); add_filter('woocommerce_gallery_image_size', array(self::class, "product_images_size"), 99); + add_action('woocommerce_before_cart', "udesly_wc_before_cart"); add_filter('template_include', [self::class, 'udesly_redirect_order_confirmation'], 99); } diff --git a/includes/misc/woocommerce.php b/includes/misc/woocommerce.php index 669f716..3134f33 100644 --- a/includes/misc/woocommerce.php +++ b/includes/misc/woocommerce.php @@ -622,7 +622,7 @@ function udesly_wc_before_cart() { // Update Shipping. Nonce check uses new value and old value (woocommerce-cart). @todo remove in 4.0. if ( ! empty( $_POST['calc_shipping'] ) && ( wp_verify_nonce( $nonce_value, 'woocommerce-shipping-calculator' ) || wp_verify_nonce( $nonce_value, 'woocommerce-cart' ) ) ) { // WPCS: input var ok. - self::calculate_shipping(); + WC_Shortcode_Cart::calculate_shipping(); // Also calc totals before we check items so subtotals etc are up to date. WC()->cart->calculate_totals(); diff --git a/udesly-adapter-plugin.php b/udesly-adapter-plugin.php index 41a4be5..5aa460b 100644 --- a/udesly-adapter-plugin.php +++ b/udesly-adapter-plugin.php @@ -11,7 +11,7 @@ * Plugin Name: Udesly Adapter * Plugin URI: https://www.udesly.com * Description: This is a support plugin for Udesly (Webflow to WordPress converter) that allows you to enable additional features for your theme. - * Version: 2.0.19 + * Version: 2.0.20 * Author: Udesly * Author URI: https://www.udesly.com * License: GPL-2.0+ @@ -29,7 +29,7 @@ // Constants defined('UDESLY_ADAPTER_PLUGIN_DIRECTORY_PATH') ?: define('UDESLY_ADAPTER_PLUGIN_DIRECTORY_PATH', plugin_dir_path(__FILE__)); defined('UDESLY_ADAPTER_PLUGIN_DIRECTORY_URL') ?: define('UDESLY_ADAPTER_PLUGIN_DIRECTORY_URL', plugin_dir_url(__FILE__)); -defined('UDESLY_ADAPTER_VERSION') ?: define('UDESLY_ADAPTER_VERSION', "2.0.19"); +defined('UDESLY_ADAPTER_VERSION') ?: define('UDESLY_ADAPTER_VERSION', "2.0.20"); defined('UDESLY_TEXT_DOMAIN') ?: define('UDESLY_TEXT_DOMAIN', "udesly-adapter-plugin"); defined('UDESLY_ADAPTER_PLUGIN_MISC_PATH') ?: define('UDESLY_ADAPTER_PLUGIN_MISC_PATH', plugin_dir_path(__FILE__) . 'includes/misc/');