diff options
Diffstat (limited to 'src/lib/api/feed')
-rw-r--r-- | src/lib/api/feed/likes.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/api/feed/likes.ts b/src/lib/api/feed/likes.ts index a4e84d8f1..378446ce9 100644 --- a/src/lib/api/feed/likes.ts +++ b/src/lib/api/feed/likes.ts @@ -42,8 +42,10 @@ export class LikesFeedAPI implements FeedAPI { limit, }) if (res.success) { + // HACKFIX: the API incorrectly returns a cursor when there are no items -sfn + const isEmptyPage = res.data.feed.length === 0 return { - cursor: res.data.cursor, + cursor: isEmptyPage ? undefined : res.data.cursor, feed: res.data.feed, } } |