@@ -76,7 +76,7 @@ discard block |
||
| 76 | 76 | ))->GetToken2Result; |
| 77 | 77 | $result = json_decode($response); |
| 78 | 78 | |
| 79 | - if (! isset($result->ResCod) || ! in_array($result->ResCod, ['0', '00'])) { |
|
| 79 | + if (!isset($result->ResCod) || !in_array($result->ResCod, ['0', '00'])) { |
|
| 80 | 80 | // error has happened |
| 81 | 81 | throw new PurchaseFailedException($result->Message); |
| 82 | 82 | } |
@@ -119,7 +119,7 @@ discard block |
||
| 119 | 119 | public function verify() : ReceiptInterface |
| 120 | 120 | { |
| 121 | 121 | $resCode = $this->invoice->getTransactionId() ?? Request::input('ResCod'); |
| 122 | - if (! isset($resCode) || !in_array($resCode, array('0', '00'))) { |
|
| 122 | + if (!isset($resCode) || !in_array($resCode, array('0', '00'))) { |
|
| 123 | 123 | $message = 'پرداخت توسط کاربر لغو شد'; |
| 124 | 124 | throw new InvalidPaymentException($message); |
| 125 | 125 | } |
@@ -137,7 +137,7 @@ discard block |
||
| 137 | 137 | $response = $client->Confirm2($data)->Confirm2Result; |
| 138 | 138 | $result = json_decode($response); |
| 139 | 139 | |
| 140 | - if (! isset($result->ResCod) || ! in_array($result->ResCod, array('0', '00'))) |
|
| 140 | + if (!isset($result->ResCod) || !in_array($result->ResCod, array('0', '00'))) |
|
| 141 | 141 | { |
| 142 | 142 | $message = $result->Message ?? 'خطا در انجام عملیات رخ داده است'; |
| 143 | 143 | throw new InvalidPaymentException($message); |