mirror of
https://github.com/retailcrm/graphql-php.git
synced 2025-02-06 15:59:24 +03:00
Fixed code style after recent changes
This commit is contained in:
parent
00caed811b
commit
90623f68d7
@ -4,8 +4,8 @@ declare(strict_types=1);
|
||||
|
||||
namespace GraphQL\Error;
|
||||
|
||||
use const E_USER_WARNING;
|
||||
use function trigger_error;
|
||||
use const E_USER_WARNING;
|
||||
|
||||
/**
|
||||
* Encapsulates warnings produced by the library.
|
||||
|
@ -14,6 +14,4 @@ class ArgumentNode extends Node
|
||||
|
||||
/** @var NameNode */
|
||||
public $name;
|
||||
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class BooleanValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var string */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -20,5 +20,4 @@ class DirectiveDefinitionNode extends Node implements TypeSystemDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class DirectiveNode extends Node
|
||||
|
||||
/** @var ArgumentNode[] */
|
||||
public $arguments;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class DocumentNode extends Node
|
||||
|
||||
/** @var DefinitionNode[] */
|
||||
public $definitions;
|
||||
|
||||
}
|
||||
|
@ -20,6 +20,4 @@ class EnumTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class EnumTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var EnumValueDefinitionNode[]|null */
|
||||
public $values;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class EnumValueDefinitionNode extends Node
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class EnumValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var string */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -23,5 +23,4 @@ class FieldDefinitionNode extends Node
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -23,5 +23,4 @@ class FieldNode extends Node implements SelectionNode
|
||||
|
||||
/** @var SelectionSetNode|null */
|
||||
public $selectionSet;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class FloatValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var string */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -28,6 +28,4 @@ class FragmentDefinitionNode extends Node implements ExecutableDefinitionNode, H
|
||||
|
||||
/** @var SelectionSetNode */
|
||||
public $selectionSet;
|
||||
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class FragmentSpreadNode extends Node implements SelectionNode
|
||||
|
||||
/** @var DirectiveNode[] */
|
||||
public $directives;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class InlineFragmentNode extends Node implements SelectionNode
|
||||
|
||||
/** @var SelectionSetNode */
|
||||
public $selectionSet;
|
||||
|
||||
}
|
||||
|
@ -20,5 +20,4 @@ class InputObjectTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class InputObjectTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var InputValueDefinitionNode[]|null */
|
||||
public $fields;
|
||||
|
||||
}
|
||||
|
@ -23,5 +23,4 @@ class InputValueDefinitionNode extends Node
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class IntValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var string */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -20,5 +20,4 @@ class InterfaceTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class InterfaceTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var FieldDefinitionNode[]|null */
|
||||
public $fields;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class ListTypeNode extends Node implements TypeNode
|
||||
|
||||
/** @var Node */
|
||||
public $type;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class ListValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var ValueNode[]|NodeList */
|
||||
public $values;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class NameNode extends Node implements TypeNode
|
||||
|
||||
/** @var string */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class NamedTypeNode extends Node implements TypeNode
|
||||
|
||||
/** @var NameNode */
|
||||
public $name;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class NonNullTypeNode extends Node implements TypeNode
|
||||
|
||||
/** @var NameNode | ListTypeNode */
|
||||
public $type;
|
||||
|
||||
}
|
||||
|
@ -8,5 +8,4 @@ class NullValueNode extends Node implements ValueNode
|
||||
{
|
||||
/** @var string */
|
||||
public $kind = NodeKind::NULL;
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class ObjectFieldNode extends Node
|
||||
|
||||
/** @var ValueNode */
|
||||
public $value;
|
||||
|
||||
}
|
||||
|
@ -23,6 +23,4 @@ class ObjectTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
|
||||
}
|
||||
|
@ -20,5 +20,4 @@ class ObjectTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var FieldDefinitionNode[] */
|
||||
public $fields;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class ObjectValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var ObjectFieldNode[]|NodeList */
|
||||
public $fields;
|
||||
|
||||
}
|
||||
|
@ -23,5 +23,4 @@ class OperationDefinitionNode extends Node implements ExecutableDefinitionNode,
|
||||
|
||||
/** @var SelectionSetNode */
|
||||
public $selectionSet;
|
||||
|
||||
}
|
||||
|
@ -18,5 +18,4 @@ class OperationTypeDefinitionNode extends Node
|
||||
|
||||
/** @var NamedTypeNode */
|
||||
public $type;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class ScalarTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class ScalarTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var DirectiveNode[]|null */
|
||||
public $directives;
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class SchemaDefinitionNode extends Node implements TypeSystemDefinitionNode
|
||||
|
||||
/** @var OperationTypeDefinitionNode[] */
|
||||
public $operationTypes;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class SelectionSetNode extends Node
|
||||
|
||||
/** @var SelectionNode[] */
|
||||
public $selections;
|
||||
|
||||
}
|
||||
|
@ -14,5 +14,4 @@ class StringValueNode extends Node implements ValueNode
|
||||
|
||||
/** @var bool|null */
|
||||
public $block;
|
||||
|
||||
}
|
||||
|
@ -20,5 +20,4 @@ class UnionTypeDefinitionNode extends Node implements TypeDefinitionNode
|
||||
|
||||
/** @var StringValueNode|null */
|
||||
public $description;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class UnionTypeExtensionNode extends Node implements TypeExtensionNode
|
||||
|
||||
/** @var NamedTypeNode[]|null */
|
||||
public $types;
|
||||
|
||||
}
|
||||
|
@ -17,5 +17,4 @@ class VariableDefinitionNode extends Node implements DefinitionNode
|
||||
|
||||
/** @var ValueNode|null */
|
||||
public $defaultValue;
|
||||
|
||||
}
|
||||
|
@ -11,5 +11,4 @@ class VariableNode extends Node
|
||||
|
||||
/** @var NameNode */
|
||||
public $name;
|
||||
|
||||
}
|
||||
|
@ -49,9 +49,7 @@ use function is_int;
|
||||
use function is_object;
|
||||
use function is_string;
|
||||
use function iterator_to_array;
|
||||
use function json_encode;
|
||||
use function property_exists;
|
||||
use function substr;
|
||||
|
||||
/**
|
||||
* Various utilities dealing with AST
|
||||
@ -278,9 +276,7 @@ class AST
|
||||
|
||||
// Use json_encode, which uses the same string encoding as GraphQL,
|
||||
// then remove the quotes.
|
||||
return new StringValueNode([
|
||||
'value' => $serialized
|
||||
]);
|
||||
return new StringValueNode(['value' => $serialized]);
|
||||
}
|
||||
|
||||
throw new InvariantViolation('Cannot convert value to AST: ' . Utils::printSafe($serialized));
|
||||
|
@ -31,6 +31,7 @@ use function array_map;
|
||||
use function array_merge;
|
||||
use function array_pop;
|
||||
use function count;
|
||||
use function is_array;
|
||||
use function sprintf;
|
||||
|
||||
/**
|
||||
@ -198,9 +199,8 @@ class TypeInfo
|
||||
}
|
||||
|
||||
/**
|
||||
* @param Directive $directive
|
||||
* @param array $typeMap
|
||||
* @return array
|
||||
* @param Type[] $typeMap
|
||||
* @return Type[]
|
||||
*/
|
||||
public static function extractTypesFromDirectives(Directive $directive, array $typeMap = [])
|
||||
{
|
||||
|
@ -181,7 +181,7 @@ class Utils
|
||||
$map = [];
|
||||
foreach ($traversable as $key => $value) {
|
||||
list($newKey, $newValue) = $fn($value, $key);
|
||||
$map[$newKey] = $newValue;
|
||||
$map[$newKey] = $newValue;
|
||||
}
|
||||
|
||||
return $map;
|
||||
|
@ -191,7 +191,7 @@ class ValidationContext
|
||||
{
|
||||
$spreads = $this->fragmentSpreads[$node] ?? null;
|
||||
if (! $spreads) {
|
||||
$spreads = [];
|
||||
$spreads = [];
|
||||
/** @var SelectionSetNode[] $setsToVisit */
|
||||
$setsToVisit = [$node->selectionSet];
|
||||
while (! empty($setsToVisit)) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user