Skip to content

Commit f777a32

Browse files
committed
Add return typehints for Symfony compatibility
1 parent 1fa783e commit f777a32

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/BazingaGeocoderBundle.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class BazingaGeocoderBundle extends Bundle
2626
/**
2727
* @return void
2828
*/
29-
public function build(ContainerBuilder $container)
29+
public function build(ContainerBuilder $container): void
3030
{
3131
parent::build($container);
3232

tests/Functional/CustomTestKernel.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class CustomTestKernel extends TestKernel
3030
{
3131
private $warmupDir;
3232

33-
public function reboot(?string $warmupDir)
33+
public function reboot(?string $warmupDir): void
3434
{
3535
$this->shutdown();
3636
$this->warmupDir = $warmupDir;
@@ -65,6 +65,10 @@ protected function getKernelParameters(): array
6565
'kernel.project_dir' => realpath($this->getProjectDir()) ?: $this->getProjectDir(),
6666
'kernel.environment' => $this->environment,
6767
'kernel.runtime_environment' => '%env(default:kernel.environment:APP_RUNTIME_ENV)%',
68+
'kernel.runtime_mode' => '%env(query_string:default:container.runtime_mode:APP_RUNTIME_MODE)%',
69+
'kernel.runtime_mode.web' => '%env(bool:default::key:web:default:kernel.runtime_mode:)%',
70+
'kernel.runtime_mode.cli' => '%env(not:default:kernel.runtime_mode.web:)%',
71+
'kernel.runtime_mode.worker' => '%env(bool:default::key:worker:default:kernel.runtime_mode:)%',
6872
'kernel.debug' => $this->debug,
6973
'kernel.build_dir' => realpath($buildDir = $this->warmupDir ?: $this->getBuildDir()) ?: $buildDir,
7074
'kernel.cache_dir' => realpath($cacheDir = ($this->getCacheDir() === $this->getBuildDir() ? ($this->warmupDir ?: $this->getCacheDir()) : $this->getCacheDir())) ?: $cacheDir,
@@ -73,6 +77,7 @@ protected function getKernelParameters(): array
7377
'kernel.bundles_metadata' => $bundlesMetadata,
7478
'kernel.charset' => $this->getCharset(),
7579
'kernel.container_class' => $this->getContainerClass(),
80+
'kernel.share_dir' => realpath($this->getProjectDir()) ?: $this->getProjectDir(),
7681
];
7782
}
7883

0 commit comments

Comments
 (0)