Skip to content

Commit

Permalink
Merge branch 'refs/heads/release/7.5.3' into wip/add-pw-tests
Browse files Browse the repository at this point in the history
# Conflicts:
#	.idea/php.xml
  • Loading branch information
mmaymo committed Jun 1, 2024
2 parents 2c04bf8 + 2403477 commit 7b926bf
Show file tree
Hide file tree
Showing 35 changed files with 1,621 additions and 1,108 deletions.
15 changes: 12 additions & 3 deletions .idea/php.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

430 changes: 0 additions & 430 deletions changelog.txt

This file was deleted.

4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"email": "[email protected]"
},
{
"name": "Inpsyde Gmbh",
"email": "hello@inpsyde.com"
"name": "Syde Gmbh",
"email": "hello@syde.com"
}
],
"require": {
Expand Down
150 changes: 0 additions & 150 deletions deploy.sh

This file was deleted.

20 changes: 19 additions & 1 deletion inc/utils.php
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,11 @@ function mollieWooCommerceFormatCurrencyValue($value, $currency)
if (in_array($currency, $currenciesWithNoDecimals)) {
return number_format($value, 0, '.', '');
}

// trying to avoid floating point issues
$value = $value * 1000;
$value = (int) $value / 1000; //drop the last decimal after the third
$value = round($value, 3);
$value = round($value, 2, PHP_ROUND_HALF_DOWN); //round down, as seems woo like it :)
return number_format($value, 2, '.', '');
}

Expand Down Expand Up @@ -222,3 +226,17 @@ function mollieDeleteWPTranslationFiles()
}
}
}

function transformPhoneToNLFormat($phone)
{
$startsWith06 = preg_match('/^06/', $phone);
if ($startsWith06) {
$prefix = '+316';
$phone = substr($phone, 2);
if (!$phone) {
return null;
}
$phone = $prefix . $phone;
}
return $phone;
}
7 changes: 4 additions & 3 deletions mollie-payments-for-woocommerce.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,18 @@
* Plugin Name: Mollie Payments for WooCommerce
* Plugin URI: https://www.mollie.com
* Description: Accept payments in WooCommerce with the official Mollie plugin
* Version: 7.6.0
* Version: 7.5.4-beta
* Author: Mollie
* Author URI: https://www.mollie.com
* Requires at least: 5.0
* Tested up to: 6.4
* Tested up to: 6.5
* Text Domain: mollie-payments-for-woocommerce
* Domain Path: /languages
* License: GPLv2 or later
* WC requires at least: 3.9
* WC tested up to: 8.5
* WC tested up to: 8.7
* Requires PHP: 7.2
* Requires Plugins: woocommerce
*/
declare(strict_types=1);

Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
],
"authors": [
{
"name": "Inpsyde GmbH",
"homepage": "https://inpsyde.com/",
"email": "hallo@inpsyde.com",
"name": "Syde GmbH",
"homepage": "https://syde.com/",
"email": "hello@syde.com",
"role": "Company"
},
{
Expand Down
11 changes: 11 additions & 0 deletions public/images/alma.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 7b926bf

Please sign in to comment.