Skip to content

Commit

Permalink
Merge pull request #69 from hugofintecture/2.2.2
Browse files Browse the repository at this point in the history
2.2.2
  • Loading branch information
hugofintecture authored Mar 17, 2023
2 parents 01c174f + 4b1befc commit eec4abe
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions Model/Fintecture.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ class Fintecture extends AbstractMethod
{
public const CODE = 'fintecture';
public const CONFIG_PREFIX = 'payment/fintecture/';
public const MODULE_VERSION = '2.2.1';
public const MODULE_VERSION = '2.2.2';

private const PAYMENT_COMMUNICATION = 'FINTECTURE-';
private const REFUND_COMMUNICATION = 'REFUND FINTECTURE-';
Expand Down Expand Up @@ -396,7 +396,7 @@ public function createRefund(OrderInterface $order, CreditmemoInterface $creditm
}
$nbCreditmemos = $creditmemos->count() + 1;

$amount = $creditmemo->getBaseGrandTotal();
$amount = (float) $creditmemo->getBaseGrandTotal();
if (!$amount) {
$this->fintectureLogger->error('Refund', [
'message' => 'No amount on creditmemo',
Expand Down Expand Up @@ -636,7 +636,7 @@ public function generatePayload(Quote $quote, string $type, string $method = '')
'data' => [
'type' => $type,
'attributes' => [
'amount' => (string) round($quote->getBaseGrandTotal(), 2),
'amount' => (string) round((float) $quote->getBaseGrandTotal(), 2),
'currency' => $quote->getQuoteCurrencyCode(),
'communication' => self::PAYMENT_COMMUNICATION . $quote->getReservedOrderId(),
],
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
"email": "[email protected]"
},
"type": "magento2-module",
"version": "2.2.1",
"version": "2.2.2",
"license": [
"GPL-3.0"
],
Expand Down
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Fintecture_Payment" setup_version="2.2.1">
<module name="Fintecture_Payment" setup_version="2.2.2">
</module>
</config>

0 comments on commit eec4abe

Please sign in to comment.