@@ -26,7 +26,7 @@ |
||
26 | 26 | { |
27 | 27 | $this->app->register( |
28 | 28 | CompilerInterface::class, |
29 | - fn () => |
|
29 | + fn() => |
|
30 | 30 | new Compiler(Compiler::SPEC_RAILT) |
31 | 31 | ); |
32 | 32 | } |
@@ -155,7 +155,7 @@ discard block |
||
155 | 155 | public function build(iterable $ast, Document $dictionary = null): DocumentInterface |
156 | 156 | { |
157 | 157 | $registry = new Registry(); |
158 | - $factory = new Factory($dictionary ??= $this->document); |
|
158 | + $factory = new Factory($dictionary ?? = $this->document); |
|
159 | 159 | |
160 | 160 | /** |
161 | 161 | * First tree walk: |
@@ -235,7 +235,7 @@ discard block |
||
235 | 235 | { |
236 | 236 | $source = File::new($source); |
237 | 237 | |
238 | - return $this->cache[$this->hash($source)] ??= $this->parser->parse($source); |
|
238 | + return $this->cache[$this->hash($source)] ?? = $this->parser->parse($source); |
|
239 | 239 | } |
240 | 240 | |
241 | 241 | /** |
@@ -267,7 +267,7 @@ discard block |
||
267 | 267 | */ |
268 | 268 | public function withType(NamedTypeInterface $type, bool $overwrite = false): self |
269 | 269 | { |
270 | - if ($overwrite || ! $this->document->hasType($type->getName())) { |
|
270 | + if ($overwrite || !$this->document->hasType($type->getName())) { |
|
271 | 271 | $this->document->addType($type); |
272 | 272 | } |
273 | 273 | |
@@ -279,7 +279,7 @@ discard block |
||
279 | 279 | */ |
280 | 280 | public function withDirective(DirectiveInterface $directive, bool $overwrite = false): self |
281 | 281 | { |
282 | - if ($overwrite || ! $this->document->hasDirective($directive->getName())) { |
|
282 | + if ($overwrite || !$this->document->hasDirective($directive->getName())) { |
|
283 | 283 | $this->document->addDirective($directive); |
284 | 284 | } |
285 | 285 | |
@@ -291,7 +291,7 @@ discard block |
||
291 | 291 | */ |
292 | 292 | public function withSchema(SchemaInterface $schema, bool $overwrite = false): self |
293 | 293 | { |
294 | - if ($overwrite || ! $this->document->getSchema()) { |
|
294 | + if ($overwrite || !$this->document->getSchema()) { |
|
295 | 295 | $this->document->setSchema($schema); |
296 | 296 | } |
297 | 297 | |
@@ -330,7 +330,7 @@ discard block |
||
330 | 330 | */ |
331 | 331 | public function cancelAutoload(callable $loader): self |
332 | 332 | { |
333 | - $this->loaders = \array_filter($this->loaders, static function (callable $haystack) use ($loader): bool { |
|
333 | + $this->loaders = \array_filter($this->loaders, static function(callable $haystack) use ($loader): bool { |
|
334 | 334 | return $haystack !== $loader; |
335 | 335 | }); |
336 | 336 |
@@ -26,14 +26,14 @@ |
||
26 | 26 | */ |
27 | 27 | public function enter(NodeInterface $source) |
28 | 28 | { |
29 | - if (! $source instanceof ScalarTypeExtensionNode) { |
|
29 | + if (!$source instanceof ScalarTypeExtensionNode) { |
|
30 | 30 | return; |
31 | 31 | } |
32 | 32 | |
33 | 33 | /** @var ScalarType $target */ |
34 | 34 | $target = $this->document->getType($source->name->value); |
35 | 35 | |
36 | - if (! $target instanceof ScalarType) { |
|
36 | + if (!$target instanceof ScalarType) { |
|
37 | 37 | // TODO should throw an error |
38 | 38 | return; |
39 | 39 | } |
@@ -27,14 +27,14 @@ |
||
27 | 27 | */ |
28 | 28 | public function enter(NodeInterface $source) |
29 | 29 | { |
30 | - if (! $source instanceof ObjectTypeExtensionNode) { |
|
30 | + if (!$source instanceof ObjectTypeExtensionNode) { |
|
31 | 31 | return; |
32 | 32 | } |
33 | 33 | |
34 | 34 | /** @var ObjectType $target */ |
35 | 35 | $target = $this->document->getType($source->name->value); |
36 | 36 | |
37 | - if (! $target instanceof ObjectType) { |
|
37 | + if (!$target instanceof ObjectType) { |
|
38 | 38 | // TODO should throw an error |
39 | 39 | return; |
40 | 40 | } |
@@ -27,14 +27,14 @@ |
||
27 | 27 | */ |
28 | 28 | public function enter(NodeInterface $source) |
29 | 29 | { |
30 | - if (! $source instanceof InputObjectTypeExtensionNode) { |
|
30 | + if (!$source instanceof InputObjectTypeExtensionNode) { |
|
31 | 31 | return; |
32 | 32 | } |
33 | 33 | |
34 | 34 | /** @var InputObjectType $target */ |
35 | 35 | $target = $this->document->getType($source->name->value); |
36 | 36 | |
37 | - if (! $target instanceof InputObjectType) { |
|
37 | + if (!$target instanceof InputObjectType) { |
|
38 | 38 | // TODO should throw an error |
39 | 39 | return; |
40 | 40 | } |
@@ -28,14 +28,14 @@ |
||
28 | 28 | */ |
29 | 29 | public function enter(NodeInterface $source) |
30 | 30 | { |
31 | - if (! $source instanceof EnumTypeExtensionNode) { |
|
31 | + if (!$source instanceof EnumTypeExtensionNode) { |
|
32 | 32 | return; |
33 | 33 | } |
34 | 34 | |
35 | 35 | /** @var EnumType $target */ |
36 | 36 | $target = $this->document->getType($source->name->value); |
37 | 37 | |
38 | - if (! $target instanceof EnumTypeInterface) { |
|
38 | + if (!$target instanceof EnumTypeInterface) { |
|
39 | 39 | // TODO should throw an error |
40 | 40 | return; |
41 | 41 | } |
@@ -27,14 +27,14 @@ |
||
27 | 27 | */ |
28 | 28 | public function enter(NodeInterface $source) |
29 | 29 | { |
30 | - if (! $source instanceof InterfaceTypeExtensionNode) { |
|
30 | + if (!$source instanceof InterfaceTypeExtensionNode) { |
|
31 | 31 | return; |
32 | 32 | } |
33 | 33 | |
34 | 34 | /** @var InterfaceType $target */ |
35 | 35 | $target = $this->document->getType($source->name->value); |
36 | 36 | |
37 | - if (! $target instanceof InterfaceType) { |
|
37 | + if (!$target instanceof InterfaceType) { |
|
38 | 38 | // TODO should throw an error |
39 | 39 | return; |
40 | 40 | } |
@@ -27,14 +27,14 @@ |
||
27 | 27 | */ |
28 | 28 | public function enter(NodeInterface $source) |
29 | 29 | { |
30 | - if (! $source instanceof UnionTypeExtensionNode) { |
|
30 | + if (!$source instanceof UnionTypeExtensionNode) { |
|
31 | 31 | return; |
32 | 32 | } |
33 | 33 | |
34 | 34 | /** @var UnionType $target */ |
35 | 35 | $target = $this->document->getType($source->name->value); |
36 | 36 | |
37 | - if (! $target instanceof UnionType) { |
|
37 | + if (!$target instanceof UnionType) { |
|
38 | 38 | // TODO should throw an error |
39 | 39 | return; |
40 | 40 | } |
@@ -27,14 +27,14 @@ |
||
27 | 27 | */ |
28 | 28 | public function enter(NodeInterface $source) |
29 | 29 | { |
30 | - if (! $source instanceof SchemaExtensionNode) { |
|
30 | + if (!$source instanceof SchemaExtensionNode) { |
|
31 | 31 | return; |
32 | 32 | } |
33 | 33 | |
34 | 34 | /** @var Schema $target */ |
35 | 35 | $target = $this->document->getSchema(); |
36 | 36 | |
37 | - if (! $target instanceof Schema) { |
|
37 | + if (!$target instanceof Schema) { |
|
38 | 38 | // TODO should throw an error |
39 | 39 | return; |
40 | 40 | } |