mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
Remove stale time to force refreshed, start using the cached result
This commit is contained in:
parent
4bfcbde65d
commit
e6a220c984
1 changed files with 1 additions and 3 deletions
|
|
@ -260,8 +260,7 @@ export function useGetLibraryItems(
|
|||
if (idx > -1 && idx < cached.pages.length) {
|
||||
const cachedResult = cached.pages[idx]
|
||||
console.log('found cached page result: ', cachedResult)
|
||||
// check
|
||||
// return cachedResult
|
||||
return cachedResult
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -301,7 +300,6 @@ export function useGetLibraryItems(
|
|||
},
|
||||
enabled,
|
||||
initialPageParam: '0',
|
||||
staleTime: 10_000,
|
||||
getNextPageParam: (lastPage: LibraryItems, pages) => {
|
||||
return lastPage.pageInfo.hasNextPage
|
||||
? lastPage?.pageInfo?.endCursor
|
||||
|
|
|
|||
Loading…
Reference in a new issue