Skip to content

Commit 8227314

Browse files
Honor the intended collection for the model
1 parent a13b7cf commit 8227314

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Engines/TNTSearchEngine.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,7 @@ public function map(Builder $builder, $results, $model)
199199
}
200200

201201
// sort models by tnt search result set
202-
return collect($results['ids'])->map(function ($hit) use ($models) {
202+
return $model->newCollection($results['ids'])->map(function ($hit) use ($models) {
203203
if (isset($models[$hit])) {
204204
return $models[$hit];
205205
}

0 commit comments

Comments
 (0)