Merge pull request #5554 from mempool/mononaut/fix-accel-paging

fix acceleration history paging w/ undefined total
This commit is contained in:
softsimon 2024-09-28 00:02:55 +04:00 committed by GitHub
commit cb12e66a3b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -165,7 +165,7 @@ export class ServicesApiServices {
return this.getAccelerationHistoryObserveResponse$({...params, page}).pipe(
map((response) => ({
page,
total: parseInt(response.headers.get('X-Total-Count'), 10),
total: parseInt(response.headers.get('X-Total-Count'), 10) || 0,
accelerations: accelerations.concat(response.body || []),
})),
switchMap(({page, total, accelerations}) => {