Use session provider in json base page
[Sone.git] / src / main / java / net / pterodactylus / sone / web / ajax / GetNotificationsAjaxPage.java
index 59c6b2f..a61f4ec 100644 (file)
@@ -79,7 +79,7 @@ public class GetNotificationsAjaxPage extends JsonPage {
         */
        @Override
        protected JsonReturnObject createJsonObject(FreenetRequest request) {
-               Sone currentSone = getCurrentSoneWithoutCreatingSession(request.getToadletContext());
+               Sone currentSone = getCurrentSone(request.getToadletContext(), false);
                List<Notification> notifications = new ArrayList<Notification>(webInterface.getNotifications(currentSone));
                Collections.sort(notifications, Notification.CREATED_TIME_SORTER);
                ArrayNode jsonNotifications = new ArrayNode(instance);