Skip to content

Commit

Permalink
Fix missing new Collection
Browse files Browse the repository at this point in the history
  • Loading branch information
divine committed Sep 14, 2020
1 parent a4699dc commit 0804ab2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Jenssegers/Mongodb/Query/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ public function getFresh($columns = [], $returnLazy = false)
$results = iterator_to_array($this->collection->aggregate($pipeline, $options));

// Return results
return Collection($results);
return new Collection($results);
} // Distinct query
elseif ($this->distinct) {
// Return distinct results directly
Expand Down

0 comments on commit 0804ab2

Please sign in to comment.