| Conditions | 4 |
| Paths | 4 |
| Total Lines | 10 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 4 |
| Changes | 0 | ||
| 1 | <?php |
||
| 32 | 1 | public function getFiles(array $path): Traversable |
|
| 33 | { |
||
| 34 | 1 | $this->tree->setStartPath($path); |
|
| 35 | 1 | $this->tree->wantDeep(false); |
|
| 36 | 1 | $this->tree->process(); |
|
| 37 | 1 | if ($root = $this->tree->getRoot()) { |
|
| 38 | 1 | foreach ($root->getSubNodes() as $item) { |
|
| 39 | 1 | $this->arrPath->setArray($item->getPath()); |
|
| 40 | 1 | if ($this->filterExt(Stuff::fileExt($this->arrPath->getFileName()))) { |
|
| 41 | 1 | yield $this->arrPath->getFileName(); |
|
| 42 | } |
||
| 47 |