File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99
1010namespace OxidEsales \GraphQL \Base \Framework ;
1111
12- use AppendIterator ;
12+ use ArrayObject ;
1313use Kcs \ClassFinder \Finder \FinderInterface ;
1414use Kcs \ClassFinder \Finder \Psr4Finder ;
1515use Kcs \ClassFinder \Finder \ReflectionFilterTrait ;
@@ -22,20 +22,15 @@ class Psr4AggregatedFinder implements FinderInterface
2222{
2323 use ReflectionFilterTrait;
2424
25- private AppendIterator $ iterator ;
26-
27- public function __construct ()
28- {
29- $ this ->iterator = new AppendIterator ();
30- }
25+ private array $ array = [];
3126
3227 public function addFinder (Psr4Finder $ finder ): void
3328 {
34- $ this ->iterator -> append ($ finder ->getIterator ());
29+ $ this ->array = array_merge ( $ this -> array , iterator_to_array ($ finder ->getIterator () ));
3530 }
3631
3732 public function getIterator (): Traversable
3833 {
39- return $ this ->iterator ;
34+ return new ArrayObject ( $ this ->array ) ;
4035 }
4136}
You can’t perform that action at this time.
0 commit comments