Skip to content

Commit 301ebe7

Browse files
authored
Work around bug in graphql-php
The class `\GraphQL\Language\Parser` from the webonyx/graphql-php package throws an `Syntax Error: Unexpected Name "INTERFACE"` exception when the token `INTERFACE` comes last in the `DirectiveLocations` part of a directive declaration. Adding `OBJECT` as the last item removes the error.
1 parent f25f779 commit 301ebe7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/code/Magento/GraphQl/etc/schema.graphqls

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ directive @resolver(class: String="") on QUERY
3737
| INPUT_OBJECT
3838
| INPUT_FIELD_DEFINITION
3939

40-
directive @typeResolver(class: String="") on INTERFACE
40+
directive @typeResolver(class: String="") on INTERFACE | OBJECT
4141

4242
type Query {
4343
}

0 commit comments

Comments
 (0)