diff --git a/CHANGELOG.md b/CHANGELOG.md index 3bd3a6d2..b1acbabc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## v5.8.1 - 2024-12-16 + +### 🐛 Bug Fixes + +Hotfix: compatibility for Woocommerce version under 6.1.0 + ## v5.8.0 - 2024-12-12 ### Changes diff --git a/README.md b/README.md index 2f47785b..a0375117 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ - Tested up to Wordpress: 6.6.1 - Tested up to Woocommerce: 9.2.3 - Requires PHP: 5.6 -- Stable tag: 5.8.0 +- Stable tag: 5.8.1 - License: GPLv3 - License URI: https://www.gnu.org/licenses/gpl-3.0.html - Support: support@getalma.eu diff --git a/readme.txt b/readme.txt index 953c76aa..0a752bd8 100644 --- a/readme.txt +++ b/readme.txt @@ -5,7 +5,7 @@ Tags: payments, BNPL, woocommerce, ecommerce, e-commerce, payment gateway, sell, Requires at least: 4.4 Tested up to: 6.3 Requires PHP: 5.6 -Stable tag: 5.8.0 +Stable tag: 5.8.1 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html @@ -51,6 +51,12 @@ You can find more documentation on our [website](https://docs.almapay.com/docs/w == Changelog == +## v5.8.1 - 2024-12-16 + +### 🐛 Bug Fixes + +Hotfix: compatibility for Woocommerce version under 6.1.0 + ## v5.8.0 - 2024-12-12 ### Changes diff --git a/src/alma-gateway-for-woocommerce.php b/src/alma-gateway-for-woocommerce.php index 260d5fc6..3e4f324b 100644 --- a/src/alma-gateway-for-woocommerce.php +++ b/src/alma-gateway-for-woocommerce.php @@ -3,7 +3,7 @@ * Plugin Name: Alma - Pay in installments or later for WooCommerce * Plugin URI: https://docs.almapay.com/docs/woocommerce * Description: Install Alma and boost your sales! It's simple and guaranteed, your cash flow is secured. 0 commitment, 0 subscription, 0 risk. - * Version: 5.8.0 + * Version: 5.8.1 * Author: Alma * Author URI: https://almapay.com * License: GNU General Public License v3.0 @@ -33,14 +33,12 @@ * along with Alma Payment Gateway for WooCommerce. If not, see https://www.gnu.org/licenses/gpl-3.0.html. */ -use Automattic\WooCommerce\Utilities\FeaturesUtil; - if ( ! defined( 'ABSPATH' ) ) { die( 'Not allowed' ); // Exit if accessed directly. } if ( ! defined( 'ALMA_VERSION' ) ) { - define( 'ALMA_VERSION', '5.8.0' ); + define( 'ALMA_VERSION', '5.8.1' ); } if ( ! defined( 'ALMA_PLUGIN_FILE' ) ) { define( 'ALMA_PLUGIN_FILE', __FILE__ ); @@ -92,6 +90,9 @@ function () { } ); +/** + * Init custom_order_tables if available in Woocommerce version. + */ add_action( 'before_woocommerce_init', function () { @@ -101,7 +102,7 @@ function () { * * @psalm-suppress UndefinedClass */ - FeaturesUtil::declare_compatibility( 'custom_order_tables', __FILE__, true ); + \Automattic\WooCommerce\Utilities\FeaturesUtil::declare_compatibility( 'custom_order_tables', __FILE__, true ); } } );