@@ -108,9 +108,9 @@ discard block |
||
108 | 108 | |
109 | 109 | throw new PurchaseFailedException($message); |
110 | 110 | } |
111 | - if (($this->settings->version??'2')==='2') { |
|
111 | + if (($this->settings->version ?? '2') === '2') { |
|
112 | 112 | $this->invoice->transactionId($body['code']); |
113 | - }else{ |
|
113 | + } else { |
|
114 | 114 | $this->invoice->transactionId($body['paymentCode']); |
115 | 115 | } |
116 | 116 | |
@@ -141,12 +141,12 @@ discard block |
||
141 | 141 | public function verify() : ReceiptInterface |
142 | 142 | { |
143 | 143 | $refId = Request::input('refid'); |
144 | - if (($this->settings->version??'2')==='2'){ |
|
144 | + if (($this->settings->version ?? '2') === '2') { |
|
145 | 145 | $data = [ |
146 | 146 | 'amount' => $this->invoice->getAmount() / ($this->settings->currency == 'T' ? 1 : 10), // convert to toman |
147 | 147 | 'refId' => $refId, |
148 | 148 | ]; |
149 | - }else{ |
|
149 | + } else { |
|
150 | 150 | $data = [ |
151 | 151 | 'paymentRefId' => $refId |
152 | 152 | ]; |
@@ -210,7 +210,7 @@ discard block |
||
210 | 210 | */ |
211 | 211 | private function notVerified($message, $status) |
212 | 212 | { |
213 | - throw new InvalidPaymentException($message, (int)$status); |
|
213 | + throw new InvalidPaymentException($message, (int) $status); |
|
214 | 214 | } |
215 | 215 | |
216 | 216 | /** |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | } |
111 | 111 | if (($this->settings->version??'2')==='2') { |
112 | 112 | $this->invoice->transactionId($body['code']); |
113 | - }else{ |
|
113 | + } else{ |
|
114 | 114 | $this->invoice->transactionId($body['paymentCode']); |
115 | 115 | } |
116 | 116 | |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | 'amount' => $this->invoice->getAmount() / ($this->settings->currency == 'T' ? 1 : 10), // convert to toman |
147 | 147 | 'refId' => $refId, |
148 | 148 | ]; |
149 | - }else{ |
|
149 | + } else{ |
|
150 | 150 | $data = [ |
151 | 151 | 'paymentRefId' => $refId |
152 | 152 | ]; |