Passed
Pull Request — master (#38)
by Ondra
05:21 queued 01:24
created
phpstan-condition-config.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
  *
11 11
  */
12 12
 
13
-declare(strict_types = 1);
13
+declare(strict_types=1);
14 14
 
15 15
 $config = [];
16 16
 
Please login to merge, or discard this patch.
src/Signer/Signer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
     public function __construct(
25 25
         private readonly PrivateKey $privateKey,
26 26
         private readonly PublicKey $publicKey,
27
-        private readonly string|int $algorithm = OPENSSL_ALGO_SHA1
27
+        private readonly string | int $algorithm = OPENSSL_ALGO_SHA1
28 28
     ) {
29 29
     }
30 30
 
Please login to merge, or discard this patch.
src/Config/PaymentConfig.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
         private readonly MerchantNumber $merchantNumber,
26 26
         private readonly DepositFlag $depositFlag,
27 27
         private readonly string $gateway,
28
-        private readonly ResponseUrl|null $responseUrl = null
28
+        private readonly ResponseUrl | null $responseUrl = null
29 29
     ) {
30 30
     }
31 31
 
Please login to merge, or discard this patch.
src/validators.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
 /**
39 39
  * @throws InvalidArgumentException
40 40
  */
41
-function assertMaxLength(string|int|float $value, int $length, string $name): void
41
+function assertMaxLength(string | int | float $value, int $length, string $name): void
42 42
 {
43 43
     $strlen = strlen((string)$value);
44 44
     if ($strlen > $length) {
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
 /**
50 50
  * @throws InvalidArgumentException
51 51
  */
52
-function assertLength(string|int|float $value, int $length, string $name): void
52
+function assertLength(string | int | float $value, int $length, string $name): void
53 53
 {
54 54
     $strlen = strlen((string)$value);
55 55
     if ($strlen !== $length) {
Please login to merge, or discard this patch.
src/Exceptions/GPWebPayResultException.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
 
20 20
 class GPWebPayResultException extends GPWebPayException
21 21
 {
22
-    private string|null $resultText;
22
+    private string | null $resultText;
23 23
     private ResponseError $error;
24 24
 
25 25
     public function __construct(
Please login to merge, or discard this patch.
example/hanlde_response.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -33,17 +33,17 @@
 block discarded – undo
33 33
 
34 34
 // setup callbacks
35 35
 
36
-$responseProvider->addOnSuccess(function (\Pixidos\GPWebPay\Data\Response $response) {
36
+$responseProvider->addOnSuccess(function(\Pixidos\GPWebPay\Data\Response $response) {
37 37
     // do anything you need after payment is success
38 38
     echo 'Success';
39 39
 });
40 40
 // you can add more callbacks
41
-$responseProvider->addOnSuccess(function (\Pixidos\GPWebPay\Data\Response $response) {
41
+$responseProvider->addOnSuccess(function(\Pixidos\GPWebPay\Data\Response $response) {
42 42
     // do anything you need
43 43
     echo 'Success';
44 44
 });
45 45
 
46
-$responseProvider->addOnError(function (\Pixidos\GPWebPay\Exceptions\GPWebPayResultException $exception, \Pixidos\GPWebPay\Data\Response $response) {
46
+$responseProvider->addOnError(function(\Pixidos\GPWebPay\Exceptions\GPWebPayResultException $exception, \Pixidos\GPWebPay\Data\Response $response) {
47 47
     // do anything you need
48 48
     echo 'Success';
49 49
 });
Please login to merge, or discard this patch.
src/Signer/Key/AbstractKey.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
 
21 21
 abstract class AbstractKey
22 22
 {
23
-    protected OpenSSLAsymmetricKey|null $key = null;
23
+    protected OpenSSLAsymmetricKey | null $key = null;
24 24
 
25 25
     /**
26 26
      * @param string $file
Please login to merge, or discard this patch.
src/Signer/SignerProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
      * @param string $gateway
34 34
      * @return SignerInterface
35 35
      */
36
-    public function get(string|null $gateway = null): SignerInterface
36
+    public function get(string | null $gateway = null): SignerInterface
37 37
     {
38 38
         if (null === $gateway) {
39 39
             $gateway = $this->configs->getDefaultGateway();
Please login to merge, or discard this patch.
src/Config/SignerConfigProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
         $this->configs[$gateway] = $config;
31 31
     }
32 32
 
33
-    public function getConfig(string|null $gateway = null): SignerConfig
33
+    public function getConfig(string | null $gateway = null): SignerConfig
34 34
     {
35 35
         if (null === $gateway) {
36 36
             $gateway = $this->defaultGateway;
Please login to merge, or discard this patch.