From: David ‘Bombe’ Roden Date: Mon, 6 Dec 2010 04:55:52 +0000 (+0100) Subject: Mark posts and replies as known when they are removed. X-Git-Tag: 0.3.2~11 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=a4a36be82ab54c924a6c9cf6b01a7fef3f2e9124;p=Sone.git Mark posts and replies as known when they are removed. --- diff --git a/src/main/java/net/pterodactylus/sone/core/Core.java b/src/main/java/net/pterodactylus/sone/core/Core.java index 52ebfab..5d176ce 100644 --- a/src/main/java/net/pterodactylus/sone/core/Core.java +++ b/src/main/java/net/pterodactylus/sone/core/Core.java @@ -885,6 +885,9 @@ public class Core implements IdentityListener { if (!soneRescueMode) { for (Post post : storedSone.getPosts()) { posts.remove(post.getId()); + if (!sone.getPosts().contains(post)) { + markPostKnown(post); + } } } synchronized (newPosts) { @@ -902,6 +905,9 @@ public class Core implements IdentityListener { if (!soneRescueMode) { for (Reply reply : storedSone.getReplies()) { replies.remove(reply.getId()); + if (!sone.getReplies().contains(reply)) { + markReplyKnown(reply); + } } } synchronized (newReplies) {