Skip to content

Commit 22d48e9

Browse files
authored
Merge pull request overblog#736 from bartv2/patch-3
Really ignore field and not create an empty InputType
2 parents ef33fa7 + 070d523 commit 22d48e9

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/Config/Parser/AnnotationParser.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -632,7 +632,7 @@ private static function getGraphQLInputFieldsFromAnnotations(GraphClass $graphCl
632632

633633
// Ignore field with resolver when the type is an Input
634634
if (isset($fieldAnnotation->resolve)) {
635-
return [];
635+
continue;
636636
}
637637

638638
$fieldName = $reflector->getName();

tests/Config/Parser/fixtures/annotations/Input/Planet.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,11 @@
1313
*/
1414
class Planet
1515
{
16+
/**
17+
* @GQL\Field(resolve="...")
18+
*/
19+
protected string $skipField;
20+
1621
/**
1722
* @GQL\Field(type="String!")
1823
*/

0 commit comments

Comments
 (0)