We will work on Apr 26th (Saturday) and will be off from Apr 30th (Wednesday) until May 2nd (Friday) for public holiday in our country

Commit 9fdbcbb2 authored by Rik ter Beek's avatar Rik ter Beek

Fixes #72 minor style updates code

parent db1a09f9
...@@ -42,9 +42,9 @@ class RefundDataBuilder implements BuilderInterface ...@@ -42,9 +42,9 @@ class RefundDataBuilder implements BuilderInterface
private $orderPaymentCollectionFactory; private $orderPaymentCollectionFactory;
/** /**
* CaptureDataBuilder constructor. * RefundDataBuilder constructor.
*
* @param \Adyen\Payment\Helper\Data $adyenHelper * @param \Adyen\Payment\Helper\Data $adyenHelper
* @param \Adyen\Payment\Model\Resource\Order\Payment\CollectionFactory $orderPaymentCollectionFactory
*/ */
public function __construct( public function __construct(
\Adyen\Payment\Helper\Data $adyenHelper, \Adyen\Payment\Helper\Data $adyenHelper,
...@@ -105,7 +105,9 @@ class RefundDataBuilder implements BuilderInterface ...@@ -105,7 +105,9 @@ class RefundDataBuilder implements BuilderInterface
if ($amount > 0) { if ($amount > 0) {
if ($ratio) { if ($ratio) {
// refund based on ratio calculate refund amount // refund based on ratio calculate refund amount
$modificationAmount = $ratio * ($splitPayment->getAmount() - $splitPayment->getRefundedAmount()); $modificationAmount = $ratio * (
$splitPayment->getAmount() - $splitPayment->getRefundedAmount()
);
} else { } else {
// total authorised amount of the split payment // total authorised amount of the split payment
$splitPaymentAmount = $splitPayment->getAmount() - $splitPayment->getRefundedAmount(); $splitPaymentAmount = $splitPayment->getAmount() - $splitPayment->getRefundedAmount();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment