mirror of
https://github.com/retailcrm/graphql-php.git
synced 2024-11-22 12:56:05 +03:00
Updated listOfType validation to Traversable
This commit is contained in:
parent
7431f2dcc5
commit
b3932c8fbe
@ -430,7 +430,7 @@ class Executor
|
|||||||
if ($fieldType instanceof ListOfType) {
|
if ($fieldType instanceof ListOfType) {
|
||||||
$itemType = $fieldType->getWrappedType();
|
$itemType = $fieldType->getWrappedType();
|
||||||
Utils::invariant(
|
Utils::invariant(
|
||||||
is_array($result) || $result instanceof \ArrayAccess,
|
is_array($result) || $result instanceof \Traversable,
|
||||||
'User Error: expected iterable, but did not find one.'
|
'User Error: expected iterable, but did not find one.'
|
||||||
);
|
);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user