Skip to content

Commit

Permalink
fix(clients): update browse iterator (generated)
Browse files Browse the repository at this point in the history
algolia/api-clients-automation#4058

Co-authored-by: algolia-bot <[email protected]>
Co-authored-by: Thomas Raffray <[email protected]>
  • Loading branch information
algolia-bot and Fluf22 committed Oct 31, 2024
1 parent 2fe37ea commit b0ca845
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/client-search/src/searchClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@ export function createSearchClient({
indexName,
browseParams: {
cursor: previousResponse ? previousResponse.cursor : undefined,
hitsPerPage: 1000,
...browseParams,
},
},
Expand Down Expand Up @@ -456,7 +457,7 @@ export function createSearchClient({
requestOptions,
);
},
validate: (response) => response.nbHits < params.hitsPerPage,
validate: (response) => response.hits.length < params.hitsPerPage,
...browseRulesOptions,
});
},
Expand Down Expand Up @@ -501,7 +502,7 @@ export function createSearchClient({
params.page += 1;
return resp;
},
validate: (response) => response.nbHits < params.hitsPerPage,
validate: (response) => response.hits.length < params.hitsPerPage,
...browseSynonymsOptions,
});
},
Expand Down

0 comments on commit b0ca845

Please sign in to comment.