From d07f50c957382e37dc7a2a1680631f69385dbbda Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Sat, 26 Jan 2013 12:40:07 +0100 Subject: [PATCH] Add own posts and replies to all posts and replies. --- src/main/java/net/pterodactylus/sone/core/Core.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/main/java/net/pterodactylus/sone/core/Core.java b/src/main/java/net/pterodactylus/sone/core/Core.java index 54bc2cf..a10d462 100644 --- a/src/main/java/net/pterodactylus/sone/core/Core.java +++ b/src/main/java/net/pterodactylus/sone/core/Core.java @@ -1375,11 +1375,21 @@ public class Core extends AbstractService implements SoneProvider, PostProvider, knownSones.add(friend); } } + synchronized (this.posts) { + for (Post post : posts) { + this.posts.put(post.getId(), post); + } + } synchronized (knownPosts) { for (Post post : posts) { knownPosts.add(post.getId()); } } + synchronized (this.replies) { + for (PostReply postReply : replies) { + this.replies.put(postReply.getId(), postReply); + } + } synchronized (knownReplies) { for (PostReply reply : replies) { knownReplies.add(reply.getId()); -- 2.7.4