Fix variable $editValue might not be defined.

This commit is contained in:
Jeremiah VALERIE 2018-08-23 09:12:19 +02:00
parent 788581ad24
commit 68f0be08cb
No known key found for this signature in database
GPG Key ID: 668676FD50ADF244

View File

@ -6,15 +6,6 @@ use GraphQL\Language\AST\NodeKind;
use GraphQL\Language\AST\NodeList; use GraphQL\Language\AST\NodeList;
use GraphQL\Utils\TypeInfo; use GraphQL\Utils\TypeInfo;
class VisitorOperation
{
public $doBreak;
public $doContinue;
public $removeNode;
}
/** /**
* Utility for efficient AST traversal and modification. * Utility for efficient AST traversal and modification.
* *
@ -258,6 +249,7 @@ class Visitor
if ($visitFn) { if ($visitFn) {
$result = call_user_func($visitFn, $node, $key, $parent, $path, $ancestors); $result = call_user_func($visitFn, $node, $key, $parent, $path, $ancestors);
$editValue = null;
if ($result !== null) { if ($result !== null) {
if ($result instanceof VisitorOperation) { if ($result instanceof VisitorOperation) {