Skip to content

Commit

Permalink
Fixed interface compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
micperr committed Sep 11, 2019
1 parent 51a61a4 commit 6d2d45a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/SuperKernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public function run(): void
$kernel->terminate($request, $response);
}

public function enableCache(array $cacheOptions = [], string $cacheDir = null): self
public function enableCache(array $cacheOptions = [], string $cacheDir = null): SuperKernel
{
if( ! class_exists('Symfony\Bundle\FrameworkBundle\HttpCache\HttpCache')) {
throw new \RuntimeException('symfony/framework-bundle is required in order to run CacheKernel.');
Expand All @@ -85,7 +85,7 @@ public function enableCache(array $cacheOptions = [], string $cacheDir = null):
return $this;
}

public function enableProductionEnvironment(array $cacheOptions = [], string $cacheDir = null): self
public function enableProductionEnvironment(array $cacheOptions = [], string $cacheDir = null): SuperKernel
{
$this->enableCache($cacheOptions, $cacheDir);
$this->environment = self::ENV_PROD;
Expand Down
4 changes: 2 additions & 2 deletions src/SuperKernelInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
interface SuperKernelInterface
{
public function run(): void;
public function enableCache(array $cacheOptions = [], string $cacheDir = null): self;
public function enableProductionEnvironment(array $cacheOptions = [], string $cacheDir = null): self;
public function enableCache(array $cacheOptions = [], string $cacheDir = null): SuperKernel;
public function enableProductionEnvironment(array $cacheOptions = [], string $cacheDir = null): SuperKernel;
public function isEnvDev(): bool;
public function isEnvTest(): bool;
public function isEnvProd(): bool;
Expand Down

0 comments on commit 6d2d45a

Please sign in to comment.