X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fajax%2FGetNotificationsAjaxPage.java;h=e6a6a9f9f6eeb41c00ddbb3dccf61911e144e92c;hp=d86e5a85229b02d38a174025f459042703286717;hb=fd88107b013522d7620f5297386472206f320e10;hpb=d063d7366c883a8f130de67af67a84eb6d725361 diff --git a/src/main/java/net/pterodactylus/sone/web/ajax/GetNotificationsAjaxPage.java b/src/main/java/net/pterodactylus/sone/web/ajax/GetNotificationsAjaxPage.java index d86e5a8..e6a6a9f 100644 --- a/src/main/java/net/pterodactylus/sone/web/ajax/GetNotificationsAjaxPage.java +++ b/src/main/java/net/pterodactylus/sone/web/ajax/GetNotificationsAjaxPage.java @@ -25,7 +25,7 @@ import java.util.Collection; import java.util.Collections; import java.util.List; -import net.pterodactylus.sone.data.Sone; +import net.pterodactylus.sone.data.LocalSone; import net.pterodactylus.sone.main.SonePlugin; import net.pterodactylus.sone.notify.ListNotificationFilters; import net.pterodactylus.sone.web.WebInterface; @@ -81,7 +81,7 @@ public class GetNotificationsAjaxPage extends JsonPage { */ @Override protected JsonReturnObject createJsonObject(FreenetRequest request) { - Optional currentSone = getCurrentSone(request.getToadletContext(), false); + Optional currentSone = getCurrentSone(request.getToadletContext(), false); Collection notifications = webInterface.getNotifications().getNotifications(); List filteredNotifications = ListNotificationFilters.filterNotifications(notifications, currentSone.orNull()); Collections.sort(filteredNotifications, Notification.CREATED_TIME_SORTER); @@ -145,7 +145,7 @@ public class GetNotificationsAjaxPage extends JsonPage { * The current Sone (may be {@code null}) * @return The current options */ - private static JsonNode createJsonOptions(Optional currentSone) { + private static JsonNode createJsonOptions(Optional currentSone) { ObjectNode options = new ObjectNode(instance); if (currentSone.isPresent()) { options.put("ShowNotification/NewSones", currentSone.get().getOptions().isShowNewSoneNotifications());