@@ -24,7 +24,7 @@ |
||
24 | 24 | { |
25 | 25 | return $this->gatewayFactory->build('CoinGate', [ |
26 | 26 | 'apiKey' => $this->credentials->getKey1(), |
27 | - ]); |
|
27 | + ]); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | /** |
@@ -14,6 +14,6 @@ |
||
14 | 14 | |
15 | 15 | public function getSuccessResponseText(ServerRequestInterface $request): ?string |
16 | 16 | { |
17 | - return 'OK' . $request->getParsedBody()['InvId']; // https://docs.robokassa.ru/#1250 |
|
17 | + return 'OK'.$request->getParsedBody()['InvId']; // https://docs.robokassa.ru/#1250 |
|
18 | 18 | } |
19 | 19 | } |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | throw new MerchantException('Response is not successful'); |
93 | 93 | } |
94 | 94 | } catch (Exception $exception) { |
95 | - throw new MerchantException('Failed to refund a card: ' . $exception->getMessage(), $exception->getCode(), $exception); |
|
95 | + throw new MerchantException('Failed to refund a card: '.$exception->getMessage(), $exception->getCode(), $exception); |
|
96 | 96 | } |
97 | 97 | } |
98 | 98 | |
@@ -108,7 +108,7 @@ discard block |
||
108 | 108 | throw new MerchantException($response->getData()['message']); |
109 | 109 | } |
110 | 110 | } catch (Exception $exception) { |
111 | - throw new MerchantException('Failed to remove a card: ' . $exception->getMessage(), $exception->getCode(), $exception); |
|
111 | + throw new MerchantException('Failed to remove a card: '.$exception->getMessage(), $exception->getCode(), $exception); |
|
112 | 112 | } |
113 | 113 | } |
114 | 114 | |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | 'confirm' => true, |
128 | 128 | ], $ignore3dSecure))->send(); |
129 | 129 | } catch (Exception $exception) { |
130 | - throw new MerchantException('Failed to charge a card: ' . $exception->getMessage(), $exception->getCode(), $exception); |
|
130 | + throw new MerchantException('Failed to charge a card: '.$exception->getMessage(), $exception->getCode(), $exception); |
|
131 | 131 | } |
132 | 132 | |
133 | 133 | if ($response->isRedirect()) { |
@@ -286,7 +286,7 @@ discard block |
||
286 | 286 | 'capture_method' => 'manual', |
287 | 287 | ], $ignore3dSecure))->send(); |
288 | 288 | } catch (Exception $exception) { |
289 | - throw new MerchantException('Failed to authorize a payment card: ' . $exception->getMessage(), |
|
289 | + throw new MerchantException('Failed to authorize a payment card: '.$exception->getMessage(), |
|
290 | 290 | $exception->getCode(), |
291 | 291 | $exception); |
292 | 292 | } |
@@ -330,10 +330,10 @@ discard block |
||
330 | 330 | ])->send(); |
331 | 331 | |
332 | 332 | if (!$response->isCancelled()) { |
333 | - throw new MerchantException('Payment has not been canceled, actual status: ' . $response->getStatus()); |
|
333 | + throw new MerchantException('Payment has not been canceled, actual status: '.$response->getStatus()); |
|
334 | 334 | } |
335 | 335 | } catch (Exception $exception) { |
336 | - throw new MerchantException('Failed to cancel a card authorization: ' . $exception->getMessage(), |
|
336 | + throw new MerchantException('Failed to cancel a card authorization: '.$exception->getMessage(), |
|
337 | 337 | $exception->getCode(), |
338 | 338 | $exception); |
339 | 339 | } |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | $paymentIntent = $event->data->object; |
77 | 77 | // ... handle other event types |
78 | 78 | default: |
79 | - echo 'Received unknown event type ' . $event->type; |
|
79 | + echo 'Received unknown event type '.$event->type; |
|
80 | 80 | } |
81 | 81 | $pi = $paymentIntent->id; |
82 | 82 | |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | |
127 | 127 | if (isset($response->getData()['error']['message']) || isset($response->getData()['last_payment_error']['message'])) { |
128 | 128 | $message = $response->getData()['error']['message'] ?? $response->getData()['last_payment_error']['message']; |
129 | - throw new MeaningfulForUserMerchantException("Failed to charge card:\n" . $message); |
|
129 | + throw new MeaningfulForUserMerchantException("Failed to charge card:\n".$message); |
|
130 | 130 | } |
131 | 131 | |
132 | 132 | throw new MerchantException('Failed to charge card'); |