@@ -49,7 +49,7 @@ discard block |
||
| 49 | 49 | $this->handleExtensionRequest(); |
| 50 | 50 | } else { |
| 51 | 51 | $uriPath = urldecode( |
| 52 | - parse_url($_SERVER[ 'REQUEST_URI' ], PHP_URL_PATH) |
|
| 52 | + parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH) |
|
| 53 | 53 | ); |
| 54 | 54 | |
| 55 | 55 | $uriPathParts = explode('public/', $uriPath); |
@@ -307,10 +307,10 @@ discard block |
||
| 307 | 307 | */ |
| 308 | 308 | public function handleAppRequest(FrameworkModuleDataStructure $app) |
| 309 | 309 | { |
| 310 | - foreach(['','modules', 'plugins'] as $additionalSegment) { |
|
| 311 | - $segments = [ $this->uri->segments->first() ]; |
|
| 310 | + foreach (['', 'modules', 'plugins'] as $additionalSegment) { |
|
| 311 | + $segments = [$this->uri->segments->first()]; |
|
| 312 | 312 | |
| 313 | - if( ! empty($additionalSegment)) { |
|
| 313 | + if ( ! empty($additionalSegment)) { |
|
| 314 | 314 | array_unshift($segments, $additionalSegment); |
| 315 | 315 | } |
| 316 | 316 | |
@@ -342,11 +342,11 @@ discard block |
||
| 342 | 342 | $uriRoutedSegments = array_diff($uriSegments, |
| 343 | 343 | array_slice($uriSegments, ($numOfUriSegments - $i))); |
| 344 | 344 | |
| 345 | - if(count($uriRoutedSegments)) { |
|
| 346 | - if($module instanceof FrameworkModuleDataStructure) { |
|
| 345 | + if (count($uriRoutedSegments)) { |
|
| 346 | + if ($module instanceof FrameworkModuleDataStructure) { |
|
| 347 | 347 | $moduleSegments = $module->getSegments(); |
| 348 | 348 | |
| 349 | - if(count($moduleSegments)) { |
|
| 349 | + if (count($moduleSegments)) { |
|
| 350 | 350 | $uriRoutedSegments = array_merge($moduleSegments, $uriRoutedSegments); |
| 351 | 351 | } |
| 352 | 352 | } |
@@ -438,7 +438,7 @@ discard block |
||
| 438 | 438 | if (class_exists($controllerClassName)) { |
| 439 | 439 | $this->addresses->any( |
| 440 | 440 | '/', |
| 441 | - function () use ($controllerClassName) { |
|
| 441 | + function() use ($controllerClassName) { |
|
| 442 | 442 | return new $controllerClassName(); |
| 443 | 443 | } |
| 444 | 444 | ); |
@@ -453,7 +453,7 @@ discard block |
||
| 453 | 453 | if (class_exists($controllerClassName)) { |
| 454 | 454 | $this->addresses->any( |
| 455 | 455 | '/', |
| 456 | - function () use ($controllerClassName) { |
|
| 456 | + function() use ($controllerClassName) { |
|
| 457 | 457 | return new $controllerClassName(); |
| 458 | 458 | } |
| 459 | 459 | ); |
@@ -505,8 +505,8 @@ discard block |
||
| 505 | 505 | ); |
| 506 | 506 | } elseif (preg_match("/([a-zA-Z0-9\\\]+)(@)([a-zA-Z0-9\\\]+)/", $closure, $matches)) { |
| 507 | 507 | $this->setController( |
| 508 | - (new KernelControllerDataStructure($matches[ 1 ])) |
|
| 509 | - ->setRequestMethod($matches[ 3 ]), |
|
| 508 | + (new KernelControllerDataStructure($matches[1])) |
|
| 509 | + ->setRequestMethod($matches[3]), |
|
| 510 | 510 | $uriSegments |
| 511 | 511 | ); |
| 512 | 512 | } elseif (presenter()->theme->use === true) { |