Save Sones after liking stuff.
[Sone.git] / src / main / java / net / pterodactylus / sone / web / ajax / UnlikeAjaxPage.java
index 6a4dde7..fb0445b 100644 (file)
@@ -55,8 +55,10 @@ public class UnlikeAjaxPage extends JsonPage {
                }
                if ("post".equals(type)) {
                        currentSone.removeLikedPostId(id);
+                       webInterface.getCore().saveSone(currentSone);
                } else if ("reply".equals(type)) {
                        currentSone.removeLikedReplyId(id);
+                       webInterface.getCore().saveSone(currentSone);
                } else {
                        return createErrorJsonObject("invalid-type");
                }