From 7ec751d8c4b8eae893a242bc32df6fe0f40aa16e Mon Sep 17 00:00:00 2001 From: Aminul Islam Date: Thu, 8 Oct 2020 00:08:10 +0600 Subject: [PATCH] Fix currency convo --- modules/gateways/bkashlegacy.php | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/modules/gateways/bkashlegacy.php b/modules/gateways/bkashlegacy.php index 31470c1..79a6325 100644 --- a/modules/gateways/bkashlegacy.php +++ b/modules/gateways/bkashlegacy.php @@ -71,19 +71,9 @@ function bkashlegacy_config() function bkashlegacy_getTotalPayable($params) { - $rate = 1; - $gwCurrency = (int)$params['convertto']; - $clientCurrency = $params['clientdetails']['currency']; - - if (!empty($gwCurrency) && ($gwCurrency !== $clientCurrency)) { - $rate = \WHMCS\Database\Capsule::table('tblcurrencies') - ->where('id', '=', $gwCurrency) - ->value('rate'); - } - $fee = empty($params['fee']) ? 0 : (($params['fee'] / 100) * $params['amount']); - return ceil(($params['amount'] + $fee) * $rate); + return ceil($params['amount'] + $fee); } function bkashlegacy_link($params)