@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | public function getFactories() |
13 | 13 | { |
14 | 14 | return [ |
15 | - 'templates' => function (App $app): Engine { |
|
15 | + 'templates' => function(App $app): Engine { |
|
16 | 16 | $root = dirname(dirname(__DIR__)); |
17 | 17 | |
18 | 18 | $templates = new Engine($root.'/templates'); |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | |
21 | 21 | $templates->addData(['app' => $app]); |
22 | 22 | |
23 | - $templates->registerFunction('icon', function ($name) use ($icons) { |
|
23 | + $templates->registerFunction('icon', function($name) use ($icons) { |
|
24 | 24 | return $icons->get($name); |
25 | 25 | }); |
26 | 26 |
@@ -11,7 +11,7 @@ |
||
11 | 11 | public function getFactories() |
12 | 12 | { |
13 | 13 | return [ |
14 | - 'router' => function (App $app): RouterContainer { |
|
14 | + 'router' => function(App $app): RouterContainer { |
|
15 | 15 | $router = new RouterContainer(); |
16 | 16 | |
17 | 17 | $map = $router->getMap(); |
@@ -11,7 +11,7 @@ |
||
11 | 11 | public function getFactories() |
12 | 12 | { |
13 | 13 | return [ |
14 | - 'builder' => function (App $app): FormatFactory { |
|
14 | + 'builder' => function(App $app): FormatFactory { |
|
15 | 15 | return new FormatFactory($app); |
16 | 16 | } |
17 | 17 | ]; |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | public function getFactories() |
14 | 14 | { |
15 | 15 | return [ |
16 | - 'middleware' => function (App $app): Dispatcher { |
|
16 | + 'middleware' => function(App $app): Dispatcher { |
|
17 | 17 | $middleware = []; |
18 | 18 | |
19 | 19 | $middleware[] = new Middlewares\Expires(); |
@@ -22,7 +22,7 @@ discard block |
||
22 | 22 | $middleware[] = new Middlewares\ContentType(); |
23 | 23 | $middleware[] = new Middlewares\ContentLanguage(['en', 'gl', 'es']); |
24 | 24 | |
25 | - $middleware[] = function ($request, $next) use ($app) { |
|
25 | + $middleware[] = function($request, $next) use ($app) { |
|
26 | 26 | $language = $request->getHeaderLine('Accept-Language'); |
27 | 27 | $translator = new Translator(); |
28 | 28 | $translator->loadTranslations(Translations::fromPoFile(dirname(dirname(__DIR__)).'/locales/'.$language.'.po')); |