X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fajax%2FFollowSoneAjaxPage.java;h=5c3e5f44a687a5c64141c1360521cface38b8176;hb=45f92ec63dbf8134d92ceed67294faa38117b195;hp=1269b41c1a206040da867b2167fc46c562b9afc3;hpb=6db033602e7c17efc40a4a19efe705d67832fc1a;p=Sone.git diff --git a/src/main/java/net/pterodactylus/sone/web/ajax/FollowSoneAjaxPage.java b/src/main/java/net/pterodactylus/sone/web/ajax/FollowSoneAjaxPage.java index 1269b41..5c3e5f4 100644 --- a/src/main/java/net/pterodactylus/sone/web/ajax/FollowSoneAjaxPage.java +++ b/src/main/java/net/pterodactylus/sone/web/ajax/FollowSoneAjaxPage.java @@ -19,6 +19,7 @@ package net.pterodactylus.sone.web.ajax; import net.pterodactylus.sone.data.Sone; import net.pterodactylus.sone.web.WebInterface; +import net.pterodactylus.sone.web.page.FreenetRequest; import net.pterodactylus.util.json.JsonObject; /** @@ -42,7 +43,7 @@ public class FollowSoneAjaxPage extends JsonPage { * {@inheritDoc} */ @Override - protected JsonObject createJsonObject(Request request) { + protected JsonObject createJsonObject(FreenetRequest request) { String soneId = request.getHttpRequest().getParam("sone"); if (!webInterface.getCore().hasSone(soneId)) { return createErrorJsonObject("invalid-sone-id"); @@ -52,7 +53,7 @@ public class FollowSoneAjaxPage extends JsonPage { return createErrorJsonObject("auth-required"); } currentSone.addFriend(soneId); - webInterface.getCore().saveSone(currentSone); + webInterface.getCore().touchConfiguration(); return createSuccessJsonObject(); }