@@ -40,7 +40,7 @@ |
||
| 40 | 40 | $reqs = $route->getRequirements(); |
| 41 | 41 | preg_replace_callback( |
| 42 | 42 | '/{(\w+)}/', |
| 43 | - function ($matches) use ($reqs) { |
|
| 43 | + function($matches) use ($reqs) { |
|
| 44 | 44 | $req = $reqs[$matches[1]] ?? '.+'; |
| 45 | 45 | return "(?<{$matches[1]}>{$req})"; |
| 46 | 46 | }, |
@@ -23,9 +23,9 @@ |
||
| 23 | 23 | $controller = $attributes['controller'].'Controller'; |
| 24 | 24 | $action = $attributes['action'].'Action'; |
| 25 | 25 | |
| 26 | - $namespace = '\\App\\Controller\\'; |
|
| 26 | + $namespace = '\\App\\Controller\\'; |
|
| 27 | 27 | if (!class_exists($namespace.$controller)) { |
| 28 | - $namespace = '\\App\\Lib\\Controller\\'; |
|
| 28 | + $namespace = '\\App\\Lib\\Controller\\'; |
|
| 29 | 29 | } |
| 30 | 30 | $response = ($namespace.$controller)::create()->$action($request, ...$attributes['params']); |
| 31 | 31 | |