Fix bug with determing whether another page exists when performing paginated searches
This commit is contained in:
parent
d9923e1e98
commit
1c07e0a895
|
@ -244,11 +244,15 @@ exports.paginatedSearch = async (
|
|||
.setSort(sort)
|
||||
.setSortOrder(sortOrder)
|
||||
.setSortType(sortType)
|
||||
const searchUrl = builder
|
||||
.setBookmark(bookmark)
|
||||
.setLimit(limit)
|
||||
const searchUrl = builder.buildSearchURL()
|
||||
const nextUrl = builder.setLimit(1).buildSearchURL()
|
||||
.buildSearchURL()
|
||||
const searchResults = await runQuery(searchUrl)
|
||||
const nextUrl = builder
|
||||
.setBookmark(searchResults.bookmark)
|
||||
.setLimit(1)
|
||||
.buildSearchURL()
|
||||
const nextResults = await runQuery(nextUrl)
|
||||
return {
|
||||
...searchResults,
|
||||
|
|
Loading…
Reference in New Issue