Compare commits

...

2 Commits

Author SHA1 Message Date
Keyan ad1244c260
Merge pull request #1484 from stackernews/fix-wallet-logs-pagination
Fix first page of wallet logs loaded twice
2024-10-18 09:07:54 -05:00
ekzyis 49ddace73f Fix first page of wallet logs loaded twice 2024-10-18 15:10:27 +02:00
1 changed files with 1 additions and 1 deletions

View File

@ -225,7 +225,7 @@ export function useWalletLogs (wallet, initialPage = 1, logsPerPage = 10) {
const loadMore = useCallback(async () => {
if (hasMore) {
setLoading(true)
const result = await loadLogsPage(page, logsPerPage, wallet)
const result = await loadLogsPage(page + 1, logsPerPage, wallet)
setLogs(prevLogs => [...prevLogs, ...result.data])
setHasMore(result.hasMore)
setTotal(result.total)