X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fajax%2FMarkAsKnownAjaxPage.java;h=fb602db0eaa3d2e1665a6b98810ce34c30889c06;hb=541f49177de5f63a97d94fe74ffb60badbf5d4c9;hp=602f253c04116589d5cdd3038e33b09c3d9ff59c;hpb=cb7aebca2a351028dd4fdd00dcd637c6aafac79b;p=Sone.git diff --git a/src/main/java/net/pterodactylus/sone/web/ajax/MarkAsKnownAjaxPage.java b/src/main/java/net/pterodactylus/sone/web/ajax/MarkAsKnownAjaxPage.java index 602f253..fb602db 100644 --- a/src/main/java/net/pterodactylus/sone/web/ajax/MarkAsKnownAjaxPage.java +++ b/src/main/java/net/pterodactylus/sone/web/ajax/MarkAsKnownAjaxPage.java @@ -55,17 +55,17 @@ public class MarkAsKnownAjaxPage extends JsonPage { Core core = webInterface.getCore(); for (String id : ids) { if (type.equals("post")) { - Optional post = core.getPost(id); + Optional post = core.getDatabase().getPost(id); if (!post.isPresent()) { continue; } core.markPostKnown(post.get()); } else if (type.equals("reply")) { - Optional reply = core.getPostReply(id); + Optional reply = core.getDatabase().getPostReply(id); if (!reply.isPresent()) { continue; } - core.markReplyKnown(reply.get()); + reply.get().modify().setKnown().update(webInterface.getCore().postReplyUpdated()); } else if (type.equals("sone")) { Optional sone = core.getSone(id); if (!sone.isPresent()) {