diff --git a/composer.json b/composer.json index d409d212..fd46030b 100644 --- a/composer.json +++ b/composer.json @@ -75,7 +75,7 @@ "stan": "@phpstan", "stan-baseline": "tools/phpstan --generate-baseline", "stan-setup": "phive install", - "rector-setup": "cp composer.json composer.backup && composer require --dev rector/rector:\"~2.7.0\" && mv composer.backup composer.json", + "rector-setup": "cp composer.json composer.backup && composer require --dev rector/rector:\"~2.8.4\" && mv composer.backup composer.json", "rector-check": "vendor/bin/rector process --dry-run", "rector-fix": "vendor/bin/rector process", "test": "phpunit", diff --git a/rector.php b/rector.php index dfb22440..a35f9009 100644 --- a/rector.php +++ b/rector.php @@ -4,7 +4,6 @@ use Rector\Caching\ValueObject\Storage\FileCacheStorage; use Rector\CodeQuality\Rector\FuncCall\CompactToVariablesRector; use Rector\CodeQuality\Rector\If_\ArrayExplicitBoolCompareRector; -use Rector\CodeQuality\Rector\If_\ObjectExplicitBoolCompareRector; use Rector\CodingStyle\Rector\Assign\SplitDoubleAssignRector; use Rector\CodingStyle\Rector\Catch_\CatchExceptionNameMatchingTypeRector; use Rector\CodingStyle\Rector\Stmt\NewlineAfterStatementRector; @@ -54,7 +53,6 @@ NewlineAfterStatementRector::class, TypedPropertyFromCreateMockAssignRector::class, ArrayExplicitBoolCompareRector::class, - ObjectExplicitBoolCompareRector::class, RemoveUselessUnionReturnDocblockRector::class, RemoveMixedDocblockOverruledByNativeTypeRector::class, ]); diff --git a/src/Middleware/AuthenticationMiddleware.php b/src/Middleware/AuthenticationMiddleware.php index 46d1870f..d2c9faa9 100644 --- a/src/Middleware/AuthenticationMiddleware.php +++ b/src/Middleware/AuthenticationMiddleware.php @@ -76,7 +76,7 @@ public function process(ServerRequestInterface $request, RequestHandlerInterface if ($this->subject instanceof ContainerApplicationInterface) { $container = $this->subject->getContainer(); $container->add(AuthenticationService::class, $service); - } elseif ($this->container) { + } elseif ($this->container instanceof ContainerInterface) { $this->container->add(AuthenticationService::class, $service); }