From 135fd4e0f1e96ecf1c875c07eca960c05cd5df90 Mon Sep 17 00:00:00 2001 From: maryamnbyn Date: Mon, 26 Dec 2022 12:31:31 +0330 Subject: [PATCH] handle asanpardakht exception error --- src/Provider/AsanPardakhtProvider.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Provider/AsanPardakhtProvider.php b/src/Provider/AsanPardakhtProvider.php index 31188aa..e55599e 100644 --- a/src/Provider/AsanPardakhtProvider.php +++ b/src/Provider/AsanPardakhtProvider.php @@ -66,7 +66,7 @@ public function checkWalletBalance(): JsonResponse|array } catch (ClientException|\Exception $exception) { $exceptionMessage = $this->getBalanceWalletError($exception); throw new Exception((json_decode($exceptionMessage->content(), false))->message, - $exceptionMessage->statusCode); + $exceptionMessage->statusCode ?? 500); } }