From 8d5a843b36a65e33e257665123ca14a070c04ce4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Beganovi=C4=87?= Date: Mon, 15 Jun 2020 12:59:02 +0200 Subject: [PATCH] Fix public api key logic --- app/PaymentDrivers/CheckoutCom/Utilities.php | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/app/PaymentDrivers/CheckoutCom/Utilities.php b/app/PaymentDrivers/CheckoutCom/Utilities.php index e121c31b06..6c1f1b897d 100644 --- a/app/PaymentDrivers/CheckoutCom/Utilities.php +++ b/app/PaymentDrivers/CheckoutCom/Utilities.php @@ -16,12 +16,7 @@ trait Utilities { public function getPublishableKey() { - // This doesn't work since $gateway->getPublishableKey is looking for 'publishableKey' - // but we use 'publicApiKey' for Checkout.com in .env file. - - // This is dummy implementation and it needs to be fixed. - - return $this->company_gateway->getConfig()->publicApiKey; + return $this->company_gateway->getConfigField('publicApiKey'); } public function convertToCheckoutAmount($amount, $currency)