mirror of
https://gitlab.com/soapbox-pub/mkstack.git
synced 2025-09-23 17:56:07 +00:00
Update context for pagination duplication potential.
This commit is contained in:
parent
0d327372fe
commit
cf64f2ca83
@ -328,7 +328,7 @@ function useInfinitePosts() {
|
|||||||
},
|
},
|
||||||
getNextPageParam: (lastPage) => {
|
getNextPageParam: (lastPage) => {
|
||||||
if (lastPage.length === 0) return undefined;
|
if (lastPage.length === 0) return undefined;
|
||||||
return lastPage[lastPage.length - 1].created_at;
|
return lastPage[lastPage.length - 1].created_at - 1; // Subtract 1 since 'until' is inclusive
|
||||||
},
|
},
|
||||||
initialPageParam: undefined,
|
initialPageParam: undefined,
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user