diff --git a/system/Router/RouteCollection.php b/system/Router/RouteCollection.php index e0814b76d1d4..9c5403b152dc 100644 --- a/system/Router/RouteCollection.php +++ b/system/Router/RouteCollection.php @@ -1656,7 +1656,7 @@ public function getRegisteredControllers(?string $verb = '*'): array if ($verb === '*') { foreach ($this->defaultHTTPMethods as $tmpVerb) { - foreach ($this->routes[$tmpVerb] as $routeKey => $route) { + foreach ($this->routes[$tmpVerb] as $route) { $controller = $this->getControllerName($route['handler']); if ($controller !== null) { $controllers[] = $controller;