about summary refs log tree commit diff
path: root/src/state/models/notifications-view.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/state/models/notifications-view.ts')
-rw-r--r--src/state/models/notifications-view.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/state/models/notifications-view.ts b/src/state/models/notifications-view.ts
index bbd7c8080..965efb87d 100644
--- a/src/state/models/notifications-view.ts
+++ b/src/state/models/notifications-view.ts
@@ -379,8 +379,8 @@ export class NotificationsViewModel {
         }
         this._updateAll(res)
         numToFetch -= res.data.notifications.length
-        cursor = this.notifications[res.data.notifications.length - 1].indexedAt
-      } while (numToFetch > 0)
+        cursor = res.data.cursor
+      } while (cursor && numToFetch > 0)
       this._xIdle()
     } catch (e: any) {
       this._xIdle(e)