Skip to content

Commit 860a301

Browse files
javiereguiluzTobion
authored andcommitted
Use is_iterable() function when possible
1 parent cbf2e51 commit 860a301

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Finder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -669,7 +669,7 @@ public function append($iterator)
669669
$this->iterators[] = $iterator->getIterator();
670670
} elseif ($iterator instanceof \Iterator) {
671671
$this->iterators[] = $iterator;
672-
} elseif ($iterator instanceof \Traversable || \is_array($iterator)) {
672+
} elseif (is_iterable($iterator)) {
673673
$it = new \ArrayIterator();
674674
foreach ($iterator as $file) {
675675
$file = $file instanceof \SplFileInfo ? $file : new \SplFileInfo($file);

0 commit comments

Comments
 (0)