Test Failed
Push — master ( bce275...201e94 )
by
unknown
07:04
created
src/Control/AbstractGISWebServiceController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@
 block discarded – undo
55 55
             $queryParams = array_intersect_ukey(
56 56
                 $request->requestVars(),
57 57
                 $config['searchable_fields'],
58
-                function ($a, $b) {
58
+                function($a, $b) {
59 59
                     $a = explode(':', $a)[0];
60 60
                     $b = explode(':', $b)[0];
61 61
                     return strcmp($a, $b);
Please login to merge, or discard this patch.
src/Control/WebFeatureService.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -15,9 +15,9 @@  discard block
 block discarded – undo
15 15
 
16 16
     private static $type_map = [
17 17
         'Varchar' => 'string',
18
-        'Float' => 'decimal',       // key tbc
19
-        'Datetime' => 'dateTime',   // key tbc
20
-        'Int' => 'integer',         // key tbc
18
+        'Float' => 'decimal', // key tbc
19
+        'Datetime' => 'dateTime', // key tbc
20
+        'Int' => 'integer', // key tbc
21 21
     ];
22 22
 
23 23
     private static $ns = 'ssgis=https://github.com/smindel/silverstripe-gis';
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
 
80 80
         list($nsName, $nsUri) = explode('=', $config['ns']);
81 81
 
82
-        $dom = new DOMDocument('1.0','UTF-8');
82
+        $dom = new DOMDocument('1.0', 'UTF-8');
83 83
         $schema = $dom->createElementNS('http://www.w3.org/2001/XMLSchema', 'schema');
84 84
         $schema->setAttribute('elementFormDefault', 'qualified');
85 85
         $schema->setAttribute('targetNamespace', $nsUri);
@@ -157,13 +157,13 @@  discard block
 block discarded – undo
157 157
 
158 158
         list($nsName, $nsUri) = explode('=', $config['ns']);
159 159
 
160
-        $dom = new DOMDocument('1.0','UTF-8');
160
+        $dom = new DOMDocument('1.0', 'UTF-8');
161 161
 
162 162
         $featureCollection = $dom->createElement('FeatureCollection');
163 163
         $featureCollection->setAttribute('xmlns:gml', 'http://www.opengis.net/gml');
164 164
         $featureCollection->setAttribute('xmlns:' . $nsName, $nsUri);
165 165
 
166
-        foreach($list as $item) {
166
+        foreach ($list as $item) {
167 167
             if (!$item->canView()) {
168 168
                 continue;
169 169
             }
@@ -222,7 +222,7 @@  discard block
 block discarded – undo
222 222
         $line = $dom->createElement('gml:LineString');
223 223
         $line->setAttribute('srsName', 'urn:ogc:def:crs:EPSG::' . $gis->srid);
224 224
 
225
-        $posList = $dom->createElement('gml:posList', implode(' ', array_map(function($point){return implode(' ', $point);}, $gis->coordinates)));
225
+        $posList = $dom->createElement('gml:posList', implode(' ', array_map(function($point) {return implode(' ', $point); }, $gis->coordinates)));
226 226
 
227 227
         $line->appendChild($posList);
228 228
 
@@ -239,7 +239,7 @@  discard block
 block discarded – undo
239 239
 
240 240
             $linearRing = $dom->createElement('gml:LinearRing');
241 241
 
242
-            $posList = $dom->createElement('gml:posList', implode(' ', array_map(function($point){return implode(' ', $point);}, $ring)));
242
+            $posList = $dom->createElement('gml:posList', implode(' ', array_map(function($point) {return implode(' ', $point); }, $ring)));
243 243
 
244 244
             $linearRing->appendChild($posList);
245 245
 
Please login to merge, or discard this patch.
src/GIS.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -229,7 +229,7 @@
 block discarded – undo
229 229
 
230 230
     protected static function reproject_array($coordinates, $fromProj, $toProj)
231 231
     {
232
-        return self::each($coordinates, function ($coordinate) use ($fromProj, $toProj) {
232
+        return self::each($coordinates, function($coordinate) use ($fromProj, $toProj) {
233 233
             return array_slice(self::$proj4->transform($toProj, new Point($coordinate[0], $coordinate[1], $fromProj))->toArray(), 0, 2);
234 234
         });
235 235
     }
Please login to merge, or discard this patch.
src/ORM/SQLite3GISSchemaManager.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,9 @@
 block discarded – undo
6 6
 use SilverStripe\ORM\DB;
7 7
 use Smindel\GIS\GIS;
8 8
 
9
-if (!class_exists(SQLite3SchemaManager::class)) return;
9
+if (!class_exists(SQLite3SchemaManager::class)) {
10
+    return;
11
+}
10 12
 
11 13
 class SQLite3GISSchemaManager extends SQLite3SchemaManager
12 14
 {
Please login to merge, or discard this patch.