From d2e72e1a5efb89c3d2c04b741bd74dc2a610a50a Mon Sep 17 00:00:00 2001 From: David Bomba Date: Fri, 14 Jan 2022 15:50:09 +1100 Subject: [PATCH] Fixes for eWay --- app/PaymentDrivers/Eway/Token.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/PaymentDrivers/Eway/Token.php b/app/PaymentDrivers/Eway/Token.php index 7b20629ca44f..63b83b9c4840 100644 --- a/app/PaymentDrivers/Eway/Token.php +++ b/app/PaymentDrivers/Eway/Token.php @@ -60,14 +60,14 @@ class Token if(!$response_status['success']) return $this->processUnsuccessfulPayment($response); - $payment = $this->processSuccessfulPayment($response); + $payment = $this->processSuccessfulPayment($response, $cgt); return $payment; } - private function processSuccessfulPayment($response) + private function processSuccessfulPayment($response, $cgt) { $amount = array_sum(array_column($this->eway_driver->payment_hash->invoices(), 'amount')) + $this->eway_driver->payment_hash->fee_total; @@ -103,7 +103,7 @@ class Token 'error_code' => $error_code, ]; - return $this->driver_class->processUnsuccessfulTransaction($data); + return $this->eway_driver->processUnsuccessfulTransaction($data); }