Passed
Pull Request — master (#113)
by Janusz
02:09
created
src/GusApi/Util/BulkReportResponseDecoder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
      */
18 18
     public static function decode(GetBulkReportResponseRaw $bulkReportResponseRaw): array
19 19
     {
20
-        $regons = [];
20
+        $regons = [ ];
21 21
 
22 22
         if ('' === $bulkReportResponseRaw->getDanePobierzRaportZbiorczyResult()) {
23 23
             return $regons;
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
             $xmlElementsResponse = new SimpleXMLElement($bulkReportResponseRaw->getDanePobierzRaportZbiorczyResult());
28 28
 
29 29
             foreach ($xmlElementsResponse->dane as $regon) {
30
-                $regons[] = (string) $regon->regon;
30
+                $regons[ ] = (string) $regon->regon;
31 31
             }
32 32
 
33 33
             return $regons;
Please login to merge, or discard this patch.
src/GusApi/Util/FullReportResponseDecoder.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
     public static function decode(GetFullReportResponseRaw $fullReportResponseRaw): GetFullReportResponse
18 18
     {
19 19
         /** @var array<int, array<string, string>> $elements */
20
-        $elements = [];
20
+        $elements = [ ];
21 21
 
22 22
         if ('' === $fullReportResponseRaw->getDanePobierzPelnyRaportResult()) {
23 23
             return new GetFullReportResponse($elements);
@@ -28,11 +28,11 @@  discard block
 block discarded – undo
28 28
 
29 29
             foreach ($xmlElementsResponse->dane as $resultData) {
30 30
                 /** @var array<string, string> $element */
31
-                $element = [];
31
+                $element = [ ];
32 32
                 foreach ($resultData as $key => $item) {
33
-                    $element[$key] = (string) $item;
33
+                    $element[ $key ] = (string) $item;
34 34
                 }
35
-                $elements[] = $element;
35
+                $elements[ ] = $element;
36 36
             }
37 37
 
38 38
             return new GetFullReportResponse($elements);
Please login to merge, or discard this patch.
src/GusApi/Util/DataSearchDecoder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,10 +29,10 @@
 block discarded – undo
29 29
             throw new InvalidServerResponseException('Invalid server response');
30 30
         }
31 31
 
32
-        $elements = [];
32
+        $elements = [ ];
33 33
 
34 34
         foreach ($xmlElementsResponse->dane as $resultData) {
35
-            $elements[] = self::decodeSingleResult($resultData);
35
+            $elements[ ] = self::decodeSingleResult($resultData);
36 36
         }
37 37
 
38 38
         return new SearchDataResponse($elements);
Please login to merge, or discard this patch.
src/GusApi/Client/SoapActionMapper.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,10 +25,10 @@
 block discarded – undo
25 25
      */
26 26
     public static function getAction(string $functionName): string
27 27
     {
28
-        if (!isset(self::ACTIONS[$functionName])) {
28
+        if (!isset(self::ACTIONS[ $functionName ])) {
29 29
             throw new InvalidActionNameException(sprintf('Invalid action %s', $functionName));
30 30
         }
31 31
 
32
-        return self::ACTIONS[$functionName] . $functionName;
32
+        return self::ACTIONS[ $functionName ].$functionName;
33 33
     }
34 34
 }
Please login to merge, or discard this patch.
src/GusApi/Client/MultipartResponseDecoder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -8,6 +8,6 @@
 block discarded – undo
8 8
 {
9 9
     public static function decode(string $response): string
10 10
     {
11
-        return stristr((string) stristr($response, '<s:'), '</s:Envelope>', true) . '</s:Envelope>';
11
+        return stristr((string) stristr($response, '<s:'), '</s:Envelope>', true).'</s:Envelope>';
12 12
     }
13 13
 }
Please login to merge, or discard this patch.
src/GusApi/Client/GusApiClient.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -97,11 +97,11 @@
 block discarded – undo
97 97
         $soapHeaders = $this->getRequestHeaders($action, $this->location);
98 98
         $this->soapClient->__setLocation($this->location);
99 99
         $this->setHttpOptions([
100
-            'header' => 'sid: ' . $sid,
100
+            'header' => 'sid: '.$sid,
101 101
             'user_agent' => 'PHP GusApi',
102 102
         ]);
103 103
 
104
-        return $this->soapClient->__soapCall($functionName, [$request->toArray()], [], $soapHeaders);
104
+        return $this->soapClient->__soapCall($functionName, [ $request->toArray() ], [ ], $soapHeaders);
105 105
     }
106 106
 
107 107
     /**
Please login to merge, or discard this patch.
examples/readmeExample.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
         //you can change report type to other one
29 29
         $reportType = ReportTypes::REPORT_PERSON;
30 30
         echo $gusReport->getName();
31
-        echo 'Address: ' . $gusReport->getStreet() . ' ' . $gusReport->getPropertyNumber() . '/' . $gusReport->getApartmentNumber();
31
+        echo 'Address: '.$gusReport->getStreet().' '.$gusReport->getPropertyNumber().'/'.$gusReport->getApartmentNumber();
32 32
 
33 33
         $fullReport = $gus->getFullReport($gusReport, $reportType);
34 34
         var_dump($fullReport);
Please login to merge, or discard this patch.
src/GusApi/Type/Response/GetFullReportResponse.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
     /**
10 10
      * @param array<int, array<string, string>> $report
11 11
      */
12
-    public function __construct(public array $report = [])
12
+    public function __construct(public array $report = [ ])
13 13
     {
14 14
     }
15 15
 
Please login to merge, or discard this patch.
src/GusApi/Type/Response/SearchDataResponse.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@
 block discarded – undo
9 9
     /**
10 10
      * @param SearchResponseCompanyData[] $DaneSzukajResult
11 11
      */
12
-    public function __construct(public array $DaneSzukajResult = [])
12
+    public function __construct(public array $DaneSzukajResult = [ ])
13 13
     {
14 14
     }
15 15
 
Please login to merge, or discard this patch.