Skip to content

Commit 466ee3f

Browse files
committed
fix: restore strict boolean check for useControllerAttributes
1 parent 7cbb3f5 commit 466ee3f

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

system/CodeIgniter.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
use Config\Cache;
3636
use Config\Feature;
3737
use Config\Kint as KintConfig;
38-
use Config\Routing;
3938
use Config\Services;
4039
use Exception;
4140
use Kint;
@@ -909,7 +908,7 @@ protected function startController()
909908
}
910909

911910
// Execute route attributes' before() methods
912-
if ((config('Routing')->useControllerAttributes ?? true)) { // @phpstan-ignore nullCoalesce.property
911+
if ((config('Routing')->useControllerAttributes ?? true) === true) { // @phpstan-ignore nullCoalesce.property
913912
$this->benchmark->start('route_attributes_before');
914913
$attributeResponse = $this->router->executeBeforeAttributes($this->request);
915914
$this->benchmark->stop('route_attributes_before');

0 commit comments

Comments
 (0)