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 ( 7f40d4...874a03 )
by Steeven
02:45
created
src/Http/Router.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
             }
78 78
         } else {
79 79
             $uriPath = urldecode(
80
-                parse_url($_SERVER[ 'REQUEST_URI' ], PHP_URL_PATH)
80
+                parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH)
81 81
             );
82 82
 
83 83
             $uriPathParts = explode('public/', $uriPath);
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
         // Module routing
121 121
         if ($numOfUriSegments = count($uriSegments)) {
122 122
             if (empty($app)) {
123
-                if (false !== ($module = modules()->getModule( reset($uriSegments) ))) {
123
+                if (false !== ($module = modules()->getModule(reset($uriSegments)))) {
124 124
                     //array_shift($uriSegments);
125 125
                     $this->uri = $this->uri->withSegments(new KernelMessageUriSegments($uriSegments));
126 126
                     $uriString = $this->uri->getSegments()->getString();
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
                     $this->registerModule($module);
129 129
                 }
130 130
             } else {
131
-                if (false !== ($module = modules()->getModule( [$app->getParameter(), reset($uriSegments) ] ))) {
131
+                if (false !== ($module = modules()->getModule([$app->getParameter(), reset($uriSegments)]))) {
132 132
                     array_shift($uriSegments);
133 133
                     $this->uri = $this->uri->withSegments(new KernelMessageUriSegments($uriSegments));
134 134
                     $uriString = $this->uri->getSegments()->getString();
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
                 }
138 138
             }
139 139
 
140
-            if($numOfUriSegments = count($uriSegments)) {
140
+            if ($numOfUriSegments = count($uriSegments)) {
141 141
                 for ($i = 0; $i <= $numOfUriSegments; $i++) {
142 142
                     $uriRoutedSegments = array_diff($uriSegments,
143 143
                         array_slice($uriSegments, ($numOfUriSegments - $i)));
@@ -228,7 +228,7 @@  discard block
 block discarded – undo
228 228
                     if (class_exists($controllerClassName = $controllerNamespace . implode('\\',
229 229
                             array_map('studlycase', $uriRoutedSegments)))) {
230 230
 
231
-                        if($controllerClassName::$inherited) {
231
+                        if ($controllerClassName::$inherited) {
232 232
                             $uriSegments = array_diff($uriSegments, $uriRoutedSegments);
233 233
                             $this->setController(new KernelControllerDataStructure($controllerClassName),
234 234
                                 $uriSegments);
@@ -245,7 +245,7 @@  discard block
 block discarded – undo
245 245
                      * Try to find requested page
246 246
                      */
247 247
                     if (false !== ($pagesDir = $module->getResourcesDir('pages', true))) {
248
-                        if($controllerClassName = $this->getPagesControllerClassName()) {
248
+                        if ($controllerClassName = $this->getPagesControllerClassName()) {
249 249
 
250 250
                             /**
251 251
                              * Try to find from database
@@ -280,12 +280,12 @@  discard block
 block discarded – undo
280 280
                                 presenter()->page->setFile($pageFilePath);
281 281
                             } else {
282 282
                                 $pageFilePath = str_replace('.phtml', DIRECTORY_SEPARATOR . 'index.phtml', $pageFilePath);
283
-                                if(is_file($pageFilePath)) {
283
+                                if (is_file($pageFilePath)) {
284 284
                                     presenter()->page->setFile($pageFilePath);
285 285
                                 }
286 286
                             }
287 287
 
288
-                            if(presenter()->page->file instanceof SplFileInfo) {
288
+                            if (presenter()->page->file instanceof SplFileInfo) {
289 289
                                 $this->setController(
290 290
                                     (new KernelControllerDataStructure($controllerClassName))
291 291
                                         ->setRequestMethod('index')
@@ -328,19 +328,19 @@  discard block
 block discarded – undo
328 328
     {
329 329
         $modules = modules()->getArrayCopy();
330 330
 
331
-        foreach($modules as $module) {
331
+        foreach ($modules as $module) {
332 332
             $controllerClassName = $module->getNamespace() . 'Controllers\Pages';
333 333
             if ($module->getNamespace() === 'O2System\Framework\\') {
334 334
                 $controllerClassName = 'O2System\Framework\Http\Controllers\Pages';
335 335
             }
336 336
 
337
-            if(class_exists($controllerClassName)) {
337
+            if (class_exists($controllerClassName)) {
338 338
                 return $controllerClassName;
339 339
                 break;
340 340
             }
341 341
         }
342 342
 
343
-        if(class_exists('O2System\Framework\Http\Controllers\Pages')) {
343
+        if (class_exists('O2System\Framework\Http\Controllers\Pages')) {
344 344
             return 'O2System\Framework\Http\Controllers\Pages';
345 345
         }
346 346
 
@@ -391,7 +391,7 @@  discard block
 block discarded – undo
391 391
                 if (class_exists($controllerClassName)) {
392 392
                     $this->addresses->any(
393 393
                         '/',
394
-                        function () use ($controllerClassName) {
394
+                        function() use ($controllerClassName) {
395 395
                             return new $controllerClassName();
396 396
                         }
397 397
                     );
@@ -406,7 +406,7 @@  discard block
 block discarded – undo
406 406
             if (class_exists($controllerClassName)) {
407 407
                 $this->addresses->any(
408 408
                     '/',
409
-                    function () use ($controllerClassName) {
409
+                    function() use ($controllerClassName) {
410 410
                         return new $controllerClassName();
411 411
                     }
412 412
                 );
@@ -458,8 +458,8 @@  discard block
 block discarded – undo
458 458
                 );
459 459
             } elseif (preg_match("/([a-zA-Z0-9\\\]+)(@)([a-zA-Z0-9\\\]+)/", $closure, $matches)) {
460 460
                 $this->setController(
461
-                    (new KernelControllerDataStructure($matches[ 1 ]))
462
-                        ->setRequestMethod($matches[ 3 ]),
461
+                    (new KernelControllerDataStructure($matches[1]))
462
+                        ->setRequestMethod($matches[3]),
463 463
                     $uriSegments
464 464
                 );
465 465
             } elseif (presenter()->theme->use === true) {
Please login to merge, or discard this patch.
src/Services/Hooks.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
             self::POST_CONTROLLER,
119 119
             self::POST_COMMANDER,
120 120
         ])) {
121
-            $this->closures[ $offset ][ spl_object_hash($closure) ] = $closure;
121
+            $this->closures[$offset][spl_object_hash($closure)] = $closure;
122 122
         }
123 123
     }
124 124
 
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
     public function callEvent($event)
133 133
     {
134 134
         if (array_key_exists($event, $this->closures)) {
135
-            foreach ($this->closures[ $event ] as $closure) {
135
+            foreach ($this->closures[$event] as $closure) {
136 136
                 call_user_func($closure);
137 137
             }
138 138
         }
Please login to merge, or discard this patch.