diff --git a/src/Instrumentation/Symfony/Framework/Routing/TraceableRouteLoader.php b/src/Instrumentation/Symfony/Framework/Routing/TraceableRouteLoader.php index f5ba296..eb616aa 100644 --- a/src/Instrumentation/Symfony/Framework/Routing/TraceableRouteLoader.php +++ b/src/Instrumentation/Symfony/Framework/Routing/TraceableRouteLoader.php @@ -57,7 +57,9 @@ private static function parseAttribute(Route $route): void { try { $controller = $route->getDefault('_controller'); - if (true === str_contains($controller, '::')) { + if (true == is_array($controller)) { + $reflection = (new \ReflectionClass($controller[0]))->getMethod($controller[1]); + } elseif (true === str_contains($controller, '::')) { $reflection = new \ReflectionMethod($controller); } else { $reflection = new \ReflectionClass($controller);