@@ -403,7 +403,7 @@ |
||
| 403 | 403 | } |
| 404 | 404 | |
| 405 | 405 | if (!empty($types = $this->type)) { |
| 406 | - $node->setReturnType(\is_array($types) ? new UnionType(\array_map(fn ($type) => new Name($type), $types)) : $types); |
|
| 406 | + $node->setReturnType(\is_array($types) ? new UnionType(\array_map(fn($type) => new Name($type), $types)) : $types); |
|
| 407 | 407 | } |
| 408 | 408 | |
| 409 | 409 | if (!$this->factory) { |
@@ -116,7 +116,7 @@ |
||
| 116 | 116 | } |
| 117 | 117 | |
| 118 | 118 | if (!empty($type = $definition->getType())) { |
| 119 | - $proxyNode->setReturnType(\is_array($type) ? new UnionType(\array_map(fn ($type) => new Name($type), $type)) : $type); |
|
| 119 | + $proxyNode->setReturnType(\is_array($type) ? new UnionType(\array_map(fn($type) => new Name($type), $type)) : $type); |
|
| 120 | 120 | } |
| 121 | 121 | } |
| 122 | 122 | |
@@ -263,7 +263,7 @@ |
||
| 263 | 263 | $definition->withContainer($id, $this); |
| 264 | 264 | } elseif ($definition instanceof Statement) { |
| 265 | 265 | $typed = $definition->value; |
| 266 | - $definition = fn () => $this->resolver->resolve($typed, $definition->args); |
|
| 266 | + $definition = fn() => $this->resolver->resolve($typed, $definition->args); |
|
| 267 | 267 | } |
| 268 | 268 | |
| 269 | 269 | if ($autowire) { |
@@ -288,7 +288,7 @@ discard block |
||
| 288 | 288 | $astNodes[] = new Declare_([new DeclareDeclare('strict_types', $this->builder->val(1))]); |
| 289 | 289 | } |
| 290 | 290 | |
| 291 | - $parameters = \array_map(fn ($value) => $this->builder->val($value), $this->parameters); |
|
| 291 | + $parameters = \array_map(fn($value) => $this->builder->val($value), $this->parameters); |
|
| 292 | 292 | $astNodes[] = $this->doCompile($this->definitions, $parameters, $options['containerClass'])->getNode(); |
| 293 | 293 | |
| 294 | 294 | if ($options['printToString']) { |
@@ -374,7 +374,7 @@ discard block |
||
| 374 | 374 | $serviceMethods[] = $this->doCreate($id, $definition, true); |
| 375 | 375 | |
| 376 | 376 | if ($this->ignoredDefinition($definition)) { |
| 377 | - ++$this->hasPrivateServices; |
|
| 377 | + ++ $this->hasPrivateServices; |
|
| 378 | 378 | |
| 379 | 379 | continue; |
| 380 | 380 | } |
@@ -395,7 +395,7 @@ discard block |
||
| 395 | 395 | continue; |
| 396 | 396 | } |
| 397 | 397 | |
| 398 | - $ids = \array_filter($ids, fn (string $id): bool => !$this->ignoredDefinition($definitions[$id] ?? null)); |
|
| 398 | + $ids = \array_filter($ids, fn(string $id): bool => !$this->ignoredDefinition($definitions[$id] ?? null)); |
|
| 399 | 399 | $ids = \array_values($ids); // If $ids are filtered, keys should not be preserved. |
| 400 | 400 | |
| 401 | 401 | $wiredTypes[] = new ArrayItem($this->builder->val($ids), $this->builder->constFetch($type . '::class')); |