Fix first page of wallet logs loaded twice

This commit is contained in:
ekzyis 2024-10-18 15:10:27 +02:00
parent 153f47de7d
commit 49ddace73f
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)