diff --git a/app/Utils/API/PaymentNew.php b/app/Utils/API/PaymentNew.php index 17719ee..f1a4b8e 100644 --- a/app/Utils/API/PaymentNew.php +++ b/app/Utils/API/PaymentNew.php @@ -61,12 +61,16 @@ class PaymentNew { $url = "https://mdf.hr5688.com/api/createPaymentOrder"; $PaymentChannelId = 0; - if ($payeeBankName == "bKash") { + $banks = [strtoupper("bKash"), strtoupper("Nagad")]; + if (!in_array(strtoupper($payeeBankName), $banks)) { + return -1; + } + if (strtoupper($payeeBankName) == strtoupper("bKash")) { $PaymentChannelId = 34; - } else { + } + if (strtoupper($payeeBankName) == strtoupper("Nagad")) { $PaymentChannelId = 35; } - // Guzzle HTTP client $client = new Client(); // var_dump($orderId);