Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f0a3a9 commit 1aa0c58Copy full SHA for 1aa0c58
1 file changed
src/Document/Transformer/ChainTransformer.php
@@ -15,17 +15,12 @@
15
16
final class ChainTransformer implements TransformerInterface
17
{
18
- /**
19
- * @var TransformerInterface[]
20
- */
21
- private readonly array $transformers;
22
-
23
/**
24
* @param iterable<TransformerInterface> $transformers
25
*/
26
- public function __construct(iterable $transformers)
27
- {
28
- $this->transformers = $transformers instanceof \Traversable ? iterator_to_array($transformers) : $transformers;
+ public function __construct(
+ private readonly iterable $transformers,
+ ) {
29
}
30
31
public function transform(iterable $documents, array $options = []): iterable
0 commit comments