GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Push — master ( 9c3470...c852c0 )
by
unknown
02:52
created
src/Services/Loader.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -141,20 +141,20 @@  discard block
 block discarded – undo
141 141
 
142 142
         if (is_dir($baseDirectory)) {
143 143
             // initialize the namespace prefix array
144
-            if (isset($this->namespaceDirs[ $namespace ]) === false) {
145
-                $this->namespaceDirs[ $namespace ] = [];
144
+            if (isset($this->namespaceDirs[$namespace]) === false) {
145
+                $this->namespaceDirs[$namespace] = [];
146 146
             }
147 147
 
148 148
             // retain the base directory for the namespace prefix
149
-            if ( ! in_array($baseDirectory, $this->namespaceDirs[ $namespace ])) {
149
+            if ( ! in_array($baseDirectory, $this->namespaceDirs[$namespace])) {
150 150
                 if ($prepend) {
151
-                    array_unshift($this->namespaceDirs[ $namespace ], $baseDirectory);
151
+                    array_unshift($this->namespaceDirs[$namespace], $baseDirectory);
152 152
                 } else {
153
-                    array_push($this->namespaceDirs[ $namespace ], $baseDirectory);
153
+                    array_push($this->namespaceDirs[$namespace], $baseDirectory);
154 154
                 }
155 155
             }
156 156
 
157
-            $this->namespaceDirsMap[ $baseDirectory ] = $namespace;
157
+            $this->namespaceDirsMap[$baseDirectory] = $namespace;
158 158
 
159 159
             // Register Namespace Language
160 160
             language()->addFilePath($baseDirectory);
@@ -192,7 +192,7 @@  discard block
 block discarded – undo
192 192
 
193 193
         if (is_dir($publicDir) and ! in_array($publicDir, $this->publicDirs)) {
194 194
             if (isset($offset)) {
195
-                $this->publicDirs[ $offset ] = $publicDir;
195
+                $this->publicDirs[$offset] = $publicDir;
196 196
             } else {
197 197
                 $this->publicDirs[] = $publicDir;
198 198
             }
@@ -217,7 +217,7 @@  discard block
 block discarded – undo
217 217
 
218 218
         if (is_dir($resourcesDir) and ! in_array($resourcesDir, $this->resourcesDirs)) {
219 219
             if (isset($offset)) {
220
-                $this->resourcesDirs[ $offset ] = $resourcesDir;
220
+                $this->resourcesDirs[$offset] = $resourcesDir;
221 221
             } else {
222 222
                 $this->resourcesDirs[] = $resourcesDir;
223 223
             }
@@ -275,7 +275,7 @@  discard block
 block discarded – undo
275 275
         $dir = rtrim($dir, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
276 276
 
277 277
         if (array_key_exists($dir, $this->namespaceDirsMap)) {
278
-            return $this->namespaceDirsMap[ $dir ];
278
+            return $this->namespaceDirsMap[$dir];
279 279
         }
280 280
 
281 281
         return false;
@@ -316,7 +316,7 @@  discard block
 block discarded – undo
316 316
         $namespace = trim($namespace, '\\') . '\\';
317 317
 
318 318
         if (array_key_exists($namespace, $this->namespaceDirs)) {
319
-            return $this->namespaceDirs[ $namespace ];
319
+            return $this->namespaceDirs[$namespace];
320 320
         }
321 321
 
322 322
         return false;
@@ -339,7 +339,7 @@  discard block
 block discarded – undo
339 339
         }
340 340
 
341 341
         if ($this->requireFile($helper)) {
342
-            $this->loadedHelpers[ pathinfo($helper, PATHINFO_FILENAME) ][] = $helper;
342
+            $this->loadedHelpers[pathinfo($helper, PATHINFO_FILENAME)][] = $helper;
343 343
 
344 344
             return;
345 345
         }
@@ -355,17 +355,17 @@  discard block
 block discarded – undo
355 355
         }
356 356
 
357 357
         if ( ! array_key_exists($helper, $this->loadedHelpers)) {
358
-            $this->loadedHelpers[ $helper ] = [];
358
+            $this->loadedHelpers[$helper] = [];
359 359
         }
360 360
 
361 361
         foreach ($helperDirectories as $helperDirectory) {
362 362
 
363 363
             $helperFilePath = $helperDirectory . studlycase($helper) . '.php';
364 364
 
365
-            if (in_array($helperFilePath, $this->loadedHelpers[ $helper ])) {
365
+            if (in_array($helperFilePath, $this->loadedHelpers[$helper])) {
366 366
                 continue;
367 367
             } elseif ($this->requireFile($helperFilePath)) {
368
-                $this->loadedHelpers[ $helper ][] = $helperFilePath;
368
+                $this->loadedHelpers[$helper][] = $helperFilePath;
369 369
             }
370 370
         }
371 371
     }
@@ -396,7 +396,7 @@  discard block
 block discarded – undo
396 396
             if (false !== ($modules = modules()->getRegistry())) {
397 397
                 foreach ($modules as $module) {
398 398
                     if ($module instanceof Module) {
399
-                        if (empty($this->namespaceDirs[ $module->getNamespace() ])) {
399
+                        if (empty($this->namespaceDirs[$module->getNamespace()])) {
400 400
                             $this->addNamespace($module->getNamespace(), $module->getRealPath());
401 401
                         }
402 402
                     }
@@ -458,12 +458,12 @@  discard block
 block discarded – undo
458 458
     public function loadMappedFile($namespace, $relativeClass)
459 459
     {
460 460
         // are there any base directories for this namespace prefix?
461
-        if (isset($this->namespaceDirs[ $namespace ]) === false) {
461
+        if (isset($this->namespaceDirs[$namespace]) === false) {
462 462
             return false;
463 463
         }
464 464
 
465 465
         // look through base directories for this namespace prefix
466
-        foreach ($this->namespaceDirs[ $namespace ] as $namespaceDirectory) {
466
+        foreach ($this->namespaceDirs[$namespace] as $namespaceDirectory) {
467 467
 
468 468
             // replace the namespace prefix with the base directory,
469 469
             // replace namespace separators with directory separators
@@ -528,9 +528,9 @@  discard block
 block discarded – undo
528 528
     public function services(array $classes)
529 529
     {
530 530
         foreach ($classes as $name => $class) {
531
-            if(is_numeric($name)) {
531
+            if (is_numeric($name)) {
532 532
                 services()->load($class);
533
-            } elseif(is_string($name)) {
533
+            } elseif (is_string($name)) {
534 534
                 services()->load($class, $name);
535 535
             }
536 536
         }
@@ -547,7 +547,7 @@  discard block
 block discarded – undo
547 547
 
548 548
     public function models(array $models)
549 549
     {
550
-        foreach($models as $model) {
550
+        foreach ($models as $model) {
551 551
             models()->load($model);
552 552
         }
553 553
     }
Please login to merge, or discard this patch.
src/Services/Language.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
      */
60 60
     public function loadRegistry()
61 61
     {
62
-        if(empty($this->registry)) {
62
+        if (empty($this->registry)) {
63 63
             $cacheItemPool = cache()->getItemPool('default');
64 64
 
65 65
             if (cache()->hasItemPool('registry')) {
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
                             );
126 126
                         }
127 127
 
128
-                        $registry[ $package->getDirName() ] = $package;
128
+                        $registry[$package->getDirName()] = $package;
129 129
                     } elseif (is_cli()) {
130 130
                         output()->verbose(
131 131
                             (new Format())
@@ -155,7 +155,7 @@  discard block
 block discarded – undo
155 155
      */
156 156
     public function registered($package)
157 157
     {
158
-        return isset($this->registry[ $package ]);
158
+        return isset($this->registry[$package]);
159 159
     }
160 160
 
161 161
     // ------------------------------------------------------------------------
@@ -171,7 +171,7 @@  discard block
 block discarded – undo
171 171
     {
172 172
         if (isset($package)) {
173 173
             if ($this->registered($package)) {
174
-                return $this->registry[ $package ];
174
+                return $this->registry[$package];
175 175
             }
176 176
 
177 177
             return false;
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
 
183 183
     public function getDefaultMetadata()
184 184
     {
185
-        return $this->getRegistry( $this->getDefault() );
185
+        return $this->getRegistry($this->getDefault());
186 186
     }
187 187
 
188 188
     // ------------------------------------------------------------------------
Please login to merge, or discard this patch.
src/Models/Files/Model.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
             }
40 40
 
41 41
             $first = reset($this->storage);
42
-            if ( ! isset($first[ $this->primaryKey ])) {
42
+            if ( ! isset($first[$this->primaryKey])) {
43 43
                 $keys = $first->getKeys();
44 44
                 $this->primaryKey = reset($keys);
45 45
             }
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 
49 49
     public function get($property)
50 50
     {
51
-        if (empty($get[ $property ])) {
51
+        if (empty($get[$property])) {
52 52
             if (services()->has($property)) {
53 53
                 return services()->get($property);
54 54
             } elseif (array_key_exists($property, $this->validSubModels)) {
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
 
64 64
     final protected function loadSubModel($model)
65 65
     {
66
-        if (is_file($this->validSubModels[ $model ])) {
66
+        if (is_file($this->validSubModels[$model])) {
67 67
             $className = '\\' . get_called_class() . '\\' . ucfirst($model);
68 68
             $className = str_replace('\Base\\Model', '\Models', $className);
69 69
 
Please login to merge, or discard this patch.
src/Models/NoSql/Model.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
             loader()->addNamespace($reflection->name, $subModelPath);
157 157
 
158 158
             foreach (glob($subModelPath . '*.php') as $filepath) {
159
-                $this->validSubModels[ strtolower(pathinfo($filepath, PATHINFO_FILENAME)) ] = $filepath;
159
+                $this->validSubModels[strtolower(pathinfo($filepath, PATHINFO_FILENAME))] = $filepath;
160 160
             }
161 161
         }
162 162
     }
@@ -183,24 +183,24 @@  discard block
 block discarded – undo
183 183
 
184 184
     public function &__get($property)
185 185
     {
186
-        $get[ $property ] = false;
186
+        $get[$property] = false;
187 187
 
188 188
         if (services()->has($property)) {
189
-            $get[ $property ] = services()->get($property);
189
+            $get[$property] = services()->get($property);
190 190
         } elseif (array_key_exists($property, $this->validSubModels)) {
191
-            $get[ $property ] = $this->loadSubModel($property);
191
+            $get[$property] = $this->loadSubModel($property);
192 192
         } elseif (o2system()->__isset($property)) {
193
-            $get[ $property ] = o2system()->__get($property);
193
+            $get[$property] = o2system()->__get($property);
194 194
         }
195 195
 
196
-        return $get[ $property ];
196
+        return $get[$property];
197 197
     }
198 198
 
199 199
     // ------------------------------------------------------------------------
200 200
 
201 201
     final protected function loadSubModel($model)
202 202
     {
203
-        if (is_file($this->validSubModels[ $model ])) {
203
+        if (is_file($this->validSubModels[$model])) {
204 204
             $className = '\\' . get_called_class() . '\\' . ucfirst($model);
205 205
             $className = str_replace('\Base\\Model', '\Models', $className);
206 206
 
Please login to merge, or discard this patch.
src/Models/Sql/Relations/Maps/Inverse.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
         $referenceModel,
31 31
         $foreignKey = null
32 32
     ) {
33
-        $this->currentModel =& $currentModel;
33
+        $this->currentModel = & $currentModel;
34 34
         $this->currentTable = $currentModel->table;
35 35
         $this->currentPrimaryKey = $currentModel->primaryKey;
36 36
 
Please login to merge, or discard this patch.
src/Models/Sql/Traits/ModifierTrait.php 1 patch
Spacing   +38 added lines, -38 removed lines patch added patch discarded remove patch
@@ -46,8 +46,8 @@  discard block
 block discarded – undo
46 46
         }
47 47
 
48 48
         if (method_exists($this, 'getRecordOrdering')) {
49
-            if ($this->recordOrdering === true && empty($sets[ 'record_ordering' ])) {
50
-                $sets[ 'record_ordering' ] = $this->getRecordOrdering($this->table);
49
+            if ($this->recordOrdering === true && empty($sets['record_ordering'])) {
50
+                $sets['record_ordering'] = $this->getRecordOrdering($this->table);
51 51
             }
52 52
         }
53 53
 
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
     protected function insertOrUpdate(array $sets)
68 68
     {
69 69
         // Try to find
70
-        if($result = $this->qb->from($this->table)->getWhere($sets)) {
70
+        if ($result = $this->qb->from($this->table)->getWhere($sets)) {
71 71
             return $this->update($sets);
72 72
         } else {
73 73
             return $this->insert($sets);
@@ -82,8 +82,8 @@  discard block
 block discarded – undo
82 82
             foreach ($sets as $set) {
83 83
                 $this->insertRecordSets($set);
84 84
 
85
-                if ($this->recordOrdering === true && empty($sets[ 'record_ordering' ])) {
86
-                    $set[ 'record_ordering' ] = $this->getRecordOrdering($this->table);
85
+                if ($this->recordOrdering === true && empty($sets['record_ordering'])) {
86
+                    $set['record_ordering'] = $this->getRecordOrdering($this->table);
87 87
                 }
88 88
             }
89 89
         }
@@ -121,10 +121,10 @@  discard block
 block discarded – undo
121 121
 
122 122
         if (empty($where)) {
123 123
             if (empty($this->primaryKeys)) {
124
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
124
+                $where[$primaryKey] = $sets[$primaryKey];
125 125
             } else {
126 126
                 foreach ($this->primaryKeys as $primaryKey) {
127
-                    $where[ $primaryKey ] = $sets[ $primaryKey ];
127
+                    $where[$primaryKey] = $sets[$primaryKey];
128 128
                 }
129 129
             }
130 130
         }
@@ -142,8 +142,8 @@  discard block
 block discarded – undo
142 142
         }
143 143
 
144 144
         if (method_exists($this, 'getRecordOrdering')) {
145
-            if ($this->recordOrdering === true && empty($sets[ 'record_ordering' ])) {
146
-                $sets[ 'record_ordering' ] = $this->getRecordOrdering($this->table);
145
+            if ($this->recordOrdering === true && empty($sets['record_ordering'])) {
146
+                $sets['record_ordering'] = $this->getRecordOrdering($this->table);
147 147
             }
148 148
         }
149 149
 
@@ -195,10 +195,10 @@  discard block
 block discarded – undo
195 195
 
196 196
         if (empty($where)) {
197 197
             if (empty($this->primaryKeys)) {
198
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
198
+                $where[$primaryKey] = $sets[$primaryKey];
199 199
             } else {
200 200
                 foreach ($this->primaryKeys as $primaryKey) {
201
-                    $where[ $primaryKey ] = $sets[ $primaryKey ];
201
+                    $where[$primaryKey] = $sets[$primaryKey];
202 202
                 }
203 203
             }
204 204
         }
@@ -208,7 +208,7 @@  discard block
 block discarded – undo
208 208
         $this->primaryKeys = [];
209 209
 
210 210
         // Try to find
211
-        if($result = $this->qb->from($this->table)->getWhere($where)) {
211
+        if ($result = $this->qb->from($this->table)->getWhere($where)) {
212 212
             return $this->update($sets, $where);
213 213
         } else {
214 214
             return $this->insert($sets);
@@ -225,11 +225,11 @@  discard block
 block discarded – undo
225 225
 
226 226
         $where = [];
227 227
         if (empty($this->primaryKeys)) {
228
-            $where[ $primaryKey ] = $sets[ $primaryKey ];
229
-            $this->qb->where($primaryKey, $sets[ $primaryKey ]);
228
+            $where[$primaryKey] = $sets[$primaryKey];
229
+            $this->qb->where($primaryKey, $sets[$primaryKey]);
230 230
         } else {
231 231
             foreach ($this->primaryKeys as $primaryKey) {
232
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
232
+                $where[$primaryKey] = $sets[$primaryKey];
233 233
             }
234 234
         }
235 235
 
@@ -241,8 +241,8 @@  discard block
 block discarded – undo
241 241
             foreach ($sets as $set) {
242 242
                 $this->updateRecordSets($set);
243 243
 
244
-                if ($this->recordOrdering === true && empty($sets[ 'record_ordering' ])) {
245
-                    $set[ 'record_ordering' ] = $this->getRecordOrdering($this->table);
244
+                if ($this->recordOrdering === true && empty($sets['record_ordering'])) {
245
+                    $set['record_ordering'] = $this->getRecordOrdering($this->table);
246 246
                 }
247 247
             }
248 248
         }
@@ -279,19 +279,19 @@  discard block
 block discarded – undo
279 279
         $where = [];
280 280
 
281 281
         if (empty($this->primaryKeys)) {
282
-            $where[ $primaryKey ] = $id;
283
-            $sets[ $primaryKey ] = $id;
282
+            $where[$primaryKey] = $id;
283
+            $sets[$primaryKey] = $id;
284 284
         } elseif (is_array($id)) {
285 285
             foreach ($this->primaryKeys as $primaryKey) {
286
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
287
-                $sets[ $primaryKey ] = $id[ $primaryKey ];
286
+                $where[$primaryKey] = $sets[$primaryKey];
287
+                $sets[$primaryKey] = $id[$primaryKey];
288 288
             }
289 289
         } else {
290 290
             foreach ($this->primaryKeys as $primaryKey) {
291
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
291
+                $where[$primaryKey] = $sets[$primaryKey];
292 292
             }
293 293
 
294
-            $sets[ reset($this->primaryKeys) ] = $id;
294
+            $sets[reset($this->primaryKeys)] = $id;
295 295
         }
296 296
 
297 297
         // Reset Primary Keys
@@ -341,7 +341,7 @@  discard block
 block discarded – undo
341 341
         $affectedRows = [];
342 342
 
343 343
         foreach ($ids as $id) {
344
-            $affectedRows[ $id ] = $this->softDelete($id);
344
+            $affectedRows[$id] = $this->softDelete($id);
345 345
         }
346 346
 
347 347
         return $affectedRows;
@@ -354,7 +354,7 @@  discard block
 block discarded – undo
354 354
         $affectedRows = [];
355 355
 
356 356
         foreach ($ids as $id) {
357
-            $affectedRows[ $id ] = $this->softDeleteBy($id, $where);
357
+            $affectedRows[$id] = $this->softDeleteBy($id, $where);
358 358
         }
359 359
 
360 360
         return $affectedRows;
@@ -368,13 +368,13 @@  discard block
 block discarded – undo
368 368
 
369 369
         $where = [];
370 370
         if (empty($this->primaryKeys)) {
371
-            $where[ $primaryKey ] = $id;
371
+            $where[$primaryKey] = $id;
372 372
         } elseif (is_array($id)) {
373 373
             foreach ($this->primaryKeys as $primaryKey) {
374
-                $where[ $primaryKey ] = $id[ $primaryKey ];
374
+                $where[$primaryKey] = $id[$primaryKey];
375 375
             }
376 376
         } else {
377
-            $where[ reset($this->primaryKeys) ] = $id;
377
+            $where[reset($this->primaryKeys)] = $id;
378 378
         }
379 379
 
380 380
         // Reset Primary Keys
@@ -412,7 +412,7 @@  discard block
 block discarded – undo
412 412
         $affectedRows = [];
413 413
 
414 414
         foreach ($ids as $id) {
415
-            $affectedRows[ $id ] = $this->delete($id, $force);
415
+            $affectedRows[$id] = $this->delete($id, $force);
416 416
         }
417 417
 
418 418
         return $affectedRows;
@@ -423,7 +423,7 @@  discard block
 block discarded – undo
423 423
         $affectedRows = [];
424 424
 
425 425
         foreach ($ids as $id) {
426
-            $affectedRows[ $id ] = $this->deleteBy($id, $where, $force);
426
+            $affectedRows[$id] = $this->deleteBy($id, $where, $force);
427 427
         }
428 428
 
429 429
         return $affectedRows;
@@ -439,19 +439,19 @@  discard block
 block discarded – undo
439 439
         $where = [];
440 440
 
441 441
         if (empty($this->primaryKeys)) {
442
-            $where[ $primaryKey ] = $id;
443
-            $sets[ $primaryKey ] = $id;
442
+            $where[$primaryKey] = $id;
443
+            $sets[$primaryKey] = $id;
444 444
         } elseif (is_array($id)) {
445 445
             foreach ($this->primaryKeys as $primaryKey) {
446
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
447
-                $sets[ $primaryKey ] = $id[ $primaryKey ];
446
+                $where[$primaryKey] = $sets[$primaryKey];
447
+                $sets[$primaryKey] = $id[$primaryKey];
448 448
             }
449 449
         } else {
450 450
             foreach ($this->primaryKeys as $primaryKey) {
451
-                $where[ $primaryKey ] = $sets[ $primaryKey ];
451
+                $where[$primaryKey] = $sets[$primaryKey];
452 452
             }
453 453
 
454
-            $sets[ reset($this->primaryKeys) ] = $id;
454
+            $sets[reset($this->primaryKeys)] = $id;
455 455
         }
456 456
 
457 457
         // Reset Primary Keys
@@ -494,7 +494,7 @@  discard block
 block discarded – undo
494 494
         $affectedRows = [];
495 495
 
496 496
         foreach ($ids as $id) {
497
-            $affectedRows[ $id ] = $this->publish($id);
497
+            $affectedRows[$id] = $this->publish($id);
498 498
         }
499 499
 
500 500
         return $affectedRows;
@@ -507,7 +507,7 @@  discard block
 block discarded – undo
507 507
         $affectedRows = [];
508 508
 
509 509
         foreach ($ids as $id) {
510
-            $affectedRows[ $id ] = $this->publishBy($id, $where);
510
+            $affectedRows[$id] = $this->publishBy($id, $where);
511 511
         }
512 512
 
513 513
         return $affectedRows;
Please login to merge, or discard this patch.
src/Models/Sql/Traits/HierarchicalTrait.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
                         ]);
86 86
                 }
87 87
 
88
-                $update[ 'id' ] = $row->id;
88
+                $update['id'] = $row->id;
89 89
 
90 90
                 if ($this->hasChilds($row->id)) {
91 91
                     $right = $this->rebuildTree($row->id, $right, $depth + 1);
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
                         ->update($update = [
96 96
                             'record_right' => $right,
97 97
                         ]);
98
-                    $update[ 'id' ] = $row->id;
98
+                    $update['id'] = $row->id;
99 99
                 }
100 100
 
101 101
                 $i++;
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
     {
194 194
         $childs = [];
195 195
 
196
-        if($result = $this->qb
196
+        if ($result = $this->qb
197 197
             ->table($this->table)
198 198
             ->where('id_parent', $idParent)
199 199
             ->get()) {
@@ -221,7 +221,7 @@  discard block
 block discarded – undo
221 221
      */
222 222
     protected function getNumChilds($idParent)
223 223
     {
224
-        if($result = $this->qb
224
+        if ($result = $this->qb
225 225
             ->table($this->table)
226 226
             ->select('id')
227 227
             ->where('id_parent', $idParent)
Please login to merge, or discard this patch.
src/Models/Sql/Model.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -163,7 +163,7 @@  discard block
 block discarded – undo
163 163
                 if ($filepath === $filePath) {
164 164
                     continue;
165 165
                 }
166
-                $this->validSubModels[ camelcase(pathinfo($filepath, PATHINFO_FILENAME)) ] = $filepath;
166
+                $this->validSubModels[camelcase(pathinfo($filepath, PATHINFO_FILENAME))] = $filepath;
167 167
             }
168 168
         }
169 169
     }
@@ -210,7 +210,7 @@  discard block
 block discarded – undo
210 210
             }
211 211
         }
212 212
 
213
-        if (empty($get[ $property ])) {
213
+        if (empty($get[$property])) {
214 214
             if (services()->has($property)) {
215 215
                 return services()->get($property);
216 216
             } elseif ($this->hasSubModel($property)) {
@@ -251,7 +251,7 @@  discard block
 block discarded – undo
251 251
     final protected function hasSubModel($model)
252 252
     {
253 253
         if (array_key_exists($model, $this->validSubModels)) {
254
-            return (bool)is_file($this->validSubModels[ $model ]);
254
+            return (bool)is_file($this->validSubModels[$model]);
255 255
         }
256 256
 
257 257
         return false;
Please login to merge, or discard this patch.
src/Http/View.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
         );
75 75
 
76 76
         if ($this->config->offsetExists('extensions')) {
77
-            $this->setFileExtensions($this->config[ 'extensions' ]);
77
+            $this->setFileExtensions($this->config['extensions']);
78 78
         }
79 79
 
80 80
         $this->document = new Html\Document();
@@ -90,13 +90,13 @@  discard block
 block discarded – undo
90 90
      */
91 91
     public function &__get($property)
92 92
     {
93
-        $get[ $property ] = false;
93
+        $get[$property] = false;
94 94
 
95 95
         if (property_exists($this, $property)) {
96 96
             return $this->{$property};
97 97
         }
98 98
 
99
-        return $get[ $property ];
99
+        return $get[$property];
100 100
     }
101 101
 
102 102
     public function parse($string, array $vars = [])
@@ -153,8 +153,8 @@  discard block
 block discarded – undo
153 153
             $error = new ErrorException(
154 154
                 'E_VIEW_NOT_FOUND',
155 155
                 0,
156
-                @$backtrace[ 0 ][ 'file' ],
157
-                @$backtrace[ 0 ][ 'line' ],
156
+                @$backtrace[0]['file'],
157
+                @$backtrace[0]['line'],
158 158
                 [trim($filename)]
159 159
             );
160 160
 
@@ -300,7 +300,7 @@  discard block
 block discarded – undo
300 300
 
301 301
     public function render(array $options = [])
302 302
     {
303
-        if(profiler() !== false) {
303
+        if (profiler() !== false) {
304 304
             profiler()->watch('Starting View Rendering');
305 305
         }
306 306
         
@@ -405,9 +405,9 @@  discard block
 block discarded – undo
405 405
         if ($this->config->output['uglify'] === true) {
406 406
             $htmlOutput = preg_replace(
407 407
                 [
408
-                    '/\>[^\S ]+/s',     // strip whitespaces after tags, except space
409
-                    '/[^\S ]+\</s',     // strip whitespaces before tags, except space
410
-                    '/(\s)+/s',         // shorten multiple whitespace sequences
408
+                    '/\>[^\S ]+/s', // strip whitespaces after tags, except space
409
+                    '/[^\S ]+\</s', // strip whitespaces before tags, except space
410
+                    '/(\s)+/s', // shorten multiple whitespace sequences
411 411
                     '/<!--(.|\s)*?-->/', // Remove HTML comments
412 412
                     '/<!--(.*)-->/Uis',
413 413
                     "/[[:blank:]]+/",
@@ -429,7 +429,7 @@  discard block
 block discarded – undo
429 429
             $htmlOutput = $beautifier->format($htmlOutput);
430 430
         }
431 431
 
432
-        if(profiler() !== false) {
432
+        if (profiler() !== false) {
433 433
             profiler()->watch('Ending View Rendering');
434 434
         }
435 435
 
Please login to merge, or discard this patch.