Skip to content

Commit 6a7468d

Browse files
dunglasfabpot
authored andcommitted
[framework-bundle] use typehints when possible
1 parent aa9657c commit 6a7468d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

symfony/framework-bundle/3.3/src/Kernel.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,23 @@
1111
/**
1212
* @author Fabien Potencier <fabien@symfony.com>
1313
*/
14-
class Kernel extends BaseKernel
14+
final class Kernel extends BaseKernel
1515
{
1616
use MicroKernelTrait;
1717

18-
const CONFIG_EXTS = '.{php,xml,yaml,yml}';
18+
private const CONFIG_EXTS = '.{php,xml,yaml,yml}';
1919

20-
public function getCacheDir()
20+
public function getCacheDir(): string
2121
{
2222
return dirname(__DIR__).'/var/cache/'.$this->environment;
2323
}
2424

25-
public function getLogDir()
25+
public function getLogDir(): string
2626
{
2727
return dirname(__DIR__).'/var/logs';
2828
}
2929

30-
public function registerBundles()
30+
public function registerBundles(): iterable
3131
{
3232
$contents = require dirname(__DIR__).'/etc/bundles.php';
3333
foreach ($contents as $class => $envs) {
@@ -37,7 +37,7 @@ public function registerBundles()
3737
}
3838
}
3939

40-
protected function configureContainer(ContainerBuilder $container, LoaderInterface $loader)
40+
protected function configureContainer(ContainerBuilder $container, LoaderInterface $loader): void
4141
{
4242
$confDir = dirname(__DIR__).'/etc';
4343
$loader->import($confDir.'/packages/*'.self::CONFIG_EXTS, 'glob');
@@ -47,7 +47,7 @@ protected function configureContainer(ContainerBuilder $container, LoaderInterfa
4747
$loader->import($confDir.'/container'.self::CONFIG_EXTS, 'glob');
4848
}
4949

50-
protected function configureRoutes(RouteCollectionBuilder $routes)
50+
protected function configureRoutes(RouteCollectionBuilder $routes): void
5151
{
5252
$confDir = dirname(__DIR__).'/etc';
5353
if (is_dir($confDir.'/routing/')) {

0 commit comments

Comments
 (0)