Changes is_array + Traversable check to is_iterable
-is_array($foo) || $foo instanceof Traversable;
+is_iterable($foo);
Configure your rector.php
:
<?php
use Rector\Config\RectorConfig;
use Rector\Php71\Rector\BooleanOr\IsIterableRector;
return RectorConfig::configure()
->withRules([
IsIterableRector::class,
]);