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 37241e42 authored by Rik ter Beek's avatar Rik ter Beek

#72 Fix refunds for non split payments

parent 9d900ab8
...@@ -75,7 +75,9 @@ class RefundDataBuilder implements BuilderInterface ...@@ -75,7 +75,9 @@ class RefundDataBuilder implements BuilderInterface
// check if it contains a split payment // check if it contains a split payment
$orderPaymentCollection = $this->orderPaymentCollectionFactory->create(); $orderPaymentCollection = $this->orderPaymentCollectionFactory
->create()
->addFieldToFilter('payment_id', $payment->getId());
// partial refund if multiple payments check refund strategy // partial refund if multiple payments check refund strategy
if ($orderPaymentCollection->getSize() > 1) { if ($orderPaymentCollection->getSize() > 1) {
...@@ -154,7 +156,7 @@ class RefundDataBuilder implements BuilderInterface ...@@ -154,7 +156,7 @@ class RefundDataBuilder implements BuilderInterface
] ]
]; ];
} }
return $result; return $result;
} }
} }
\ No newline at end of file
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