From fd1b61cadd9596b5e2fa031a201e7acbb85f0680 Mon Sep 17 00:00:00 2001 From: Ettore Del Negro Date: Wed, 22 Apr 2026 21:23:30 +0200 Subject: [PATCH] Update annotation retrieval to use getGraphQLElement --- src/DependencyInjection/GraphQLiteCompilerPass.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/DependencyInjection/GraphQLiteCompilerPass.php b/src/DependencyInjection/GraphQLiteCompilerPass.php index 75246d6..74569a5 100644 --- a/src/DependencyInjection/GraphQLiteCompilerPass.php +++ b/src/DependencyInjection/GraphQLiteCompilerPass.php @@ -337,7 +337,7 @@ private function makePublicInjectedServices(ReflectionClass $refClass, Annotatio $services = $this->getCodeCache()->get($refClass, function() use ($refClass, $reader, $container, $isController): array { $services = []; foreach ($refClass->getMethods(ReflectionMethod::IS_PUBLIC) as $method) { - $field = $reader->getRequestAnnotation($method, Field::class) ?? $reader->getRequestAnnotation($method, Query::class) ?? $reader->getRequestAnnotation($method, Mutation::class); + $field = $reader->getGraphQLElementAnnotation($method, Field::class) ?? $reader->getGraphQLElementAnnotation($method, Query::class) ?? $reader->getGraphQLElementAnnotation($method, Mutation::class); if ($field !== null) { if ($isController) { $services[$refClass->getName()] = $refClass->getName();