diff --git a/Database/Base/CollectionIterator.php b/Database/Base/CollectionIterator.php index fb3cfd43..412ea690 100644 --- a/Database/Base/CollectionIterator.php +++ b/Database/Base/CollectionIterator.php @@ -72,7 +72,7 @@ class CollectionIterator extends \ArrayIterator */ public function current(): ActiveRecord { - if (!(($current = parent::current()) instanceof ActiveRecord)) { + if (is_array($current = parent::current())) { $current = $this->newModel($current); } return $this->query->getWith($current);