Passed
Push — master ( 0dee84...d773ea )
by Swen
03:19
created
src/Geometry/Polygon.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -299,7 +299,7 @@
 block discarded – undo
299 299
                 return false;
300 300
             }
301 301
             /** @var string $wkt */
302
-            $wkt = str_ireplace(['LINESTRING(',')'], '', $ring->asText());
302
+            $wkt = str_ireplace(['LINESTRING(', ')'], '', $ring->asText());
303 303
             $pts = array_unique(array_map('trim', explode(',', $wkt)));
304 304
             if (count($pts) < 3) {
305 305
                 return false;
Please login to merge, or discard this patch.
src/Geometry/Curve.php 1 patch
Spacing   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -121,10 +121,8 @@
 block discarded – undo
121 121
     public function boundary(): Geometry
122 122
     {
123 123
         return $this->isEmpty() ?
124
-            new LineString() :
125
-            ($this->isClosed() ?
126
-                new MultiPoint() :
127
-                new MultiPoint([$this->startPoint(), $this->endPoint()])
124
+            new LineString() : ($this->isClosed() ?
125
+                new MultiPoint() : new MultiPoint([$this->startPoint(), $this->endPoint()])
128 126
             );
129 127
     }
130 128
 
Please login to merge, or discard this patch.
src/Adapter/TWKB.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -368,7 +368,7 @@
 block discarded – undo
368 368
         
369 369
         $twkb = $this->writeGeometry($geometry);
370 370
         
371
-        return $writeAsHex ? current( (array) unpack('H*', $twkb)) : $twkb;
371
+        return $writeAsHex ? current((array) unpack('H*', $twkb)) : $twkb;
372 372
     }
373 373
 
374 374
     /**
Please login to merge, or discard this patch.
src/Adapter/OSM.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
             $lon = null;
98 98
             
99 99
             /** @var \DOMElement $node */
100
-            if($node->attributes !== null) {
100
+            if ($node->attributes !== null) {
101 101
                 $lat = $node->attributes->getNamedItem('lat')->nodeValue;
102 102
                 $lon = $node->attributes->getNamedItem('lon')->nodeValue;
103 103
                 $nodeId = intval($node->attributes->getNamedItem('id')->nodeValue);
@@ -128,14 +128,14 @@  discard block
 block discarded – undo
128 128
         $wayId = 0;
129 129
         foreach ($this->xmlObj->getElementsByTagName('way') as $way) {
130 130
             /** @var \DOMElement $way */
131
-            if($way->attributes !== null) {
131
+            if ($way->attributes !== null) {
132 132
                 $wayId = intval($way->attributes->getNamedItem('id')->nodeValue);
133 133
             } else {
134 134
                 ++$wayId;
135 135
             }
136 136
             $wayNodes = [];
137 137
             foreach ($way->getElementsByTagName('nd') as $node) {
138
-                if($node->attributes === null) {
138
+                if ($node->attributes === null) {
139 139
                     continue;
140 140
                 }
141 141
                 $ref = intval($node->attributes->getNamedItem('ref')->nodeValue);
@@ -577,7 +577,7 @@  discard block
 block discarded – undo
577 577
     {
578 578
         /** @noinspection PhpUnusedParameterInspection */
579 579
         set_error_handler(
580
-            function ($errNO, $errStr, $errFile, $errLine, $errContext) {
580
+            function($errNO, $errStr, $errFile, $errLine, $errContext) {
581 581
                 if (isset($errContext['http_response_header'])) {
582 582
                     foreach ($errContext['http_response_header'] as $line) {
583 583
                         if (strpos($line, 'Error: ') > -1) {
Please login to merge, or discard this patch.