From 7be620808f0cf4f46902ddc5637c7d75791a3582 Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Sat, 13 Apr 2024 17:09:56 +0800 Subject: [PATCH] Fix notifications for Pixelfed --- src/pages/notifications.jsx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/pages/notifications.jsx b/src/pages/notifications.jsx index b2269785..702dbe0f 100644 --- a/src/pages/notifications.jsx +++ b/src/pages/notifications.jsx @@ -72,6 +72,13 @@ function Notifications({ columnMode }) { excludeTypes: ['follow_request'], }); } + if (/max_id=($|&)/i.test(notificationsIterator.current?.nextParams)) { + // Pixelfed returns next paginationed link with empty max_id + // I assume, it's done (end of list) + return { + done: true, + }; + } const allNotifications = await notificationsIterator.current.next(); const notifications = allNotifications.value;