Only process new posts and replies if the notifications changed.
[Sone.git] / src / main / java / net / pterodactylus / sone / web / ajax / GetStatusAjaxPage.java
index 28fee14..223a79f 100644 (file)
@@ -91,6 +91,7 @@ public class GetStatusAjaxPage extends JsonPage {
                }
                /* load notifications. */
                List<Notification> notifications = ListNotificationFilters.filterNotifications(webInterface.getNotifications().getNotifications(), currentSone);
+               Collections.sort(notifications, Notification.CREATED_TIME_SORTER);
                int notificationHash = HashCode.hashCode(notifications);
                /* load new posts. */
                Set<Post> newPosts = webInterface.getNewPosts();