From 71502b10998cb63d30ede1fbe3ddd62e242d7caa Mon Sep 17 00:00:00 2001 From: Fanis <93339170+tharropoulos@users.noreply.github.com> Date: Wed, 4 Sep 2024 17:16:00 +0300 Subject: [PATCH] fix(typesense): remove builder limit assignment on paginate (#858) - Remove assignment of `perPage` to builder's limit attribute - Allows for accurate total record count beyond `perPage` value - Addresses interaction issue between `Builder` and `TypesenseEngine` - Ensures correct limit setting for Typesense server queries --- src/Engines/TypesenseEngine.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/Engines/TypesenseEngine.php b/src/Engines/TypesenseEngine.php index 73af48bc..18146989 100644 --- a/src/Engines/TypesenseEngine.php +++ b/src/Engines/TypesenseEngine.php @@ -205,8 +205,6 @@ public function search(Builder $builder) */ public function paginate(Builder $builder, $perPage, $page) { - $builder->take($builder->limit ?? $perPage); - return $this->performSearch( $builder, $this->buildSearchParameters($builder, $page, $perPage)