mirror of
https://github.com/retailcrm/graphql-php.git
synced 2024-11-25 14:26:08 +03:00
type hint Name node in visitor
This commit is contained in:
parent
46788f2ddb
commit
816fa067b3
@ -1,7 +1,6 @@
|
||||
<?php
|
||||
namespace GraphQL\Language;
|
||||
|
||||
|
||||
use GraphQL\Language\AST\Argument;
|
||||
use GraphQL\Language\AST\DirectiveDefinition;
|
||||
use GraphQL\Language\AST\EnumTypeDefinition;
|
||||
@ -22,6 +21,7 @@ use GraphQL\Language\AST\FragmentSpread;
|
||||
use GraphQL\Language\AST\InlineFragment;
|
||||
use GraphQL\Language\AST\IntValue;
|
||||
use GraphQL\Language\AST\ListType;
|
||||
use GraphQL\Language\AST\Name;
|
||||
use GraphQL\Language\AST\NamedType;
|
||||
use GraphQL\Language\AST\Node;
|
||||
use GraphQL\Language\AST\NodeType;
|
||||
@ -45,7 +45,7 @@ class Printer
|
||||
{
|
||||
return Visitor::visit($ast, [
|
||||
'leave' => [
|
||||
NodeType::NAME => function($node) {
|
||||
NodeType::NAME => function(Node $node) {
|
||||
return '' . $node->value;
|
||||
},
|
||||
NodeType::VARIABLE => function($node) {
|
||||
|
Loading…
Reference in New Issue
Block a user