From 4f1c79caddd4f38e9639f054f7a8800c2a5627b3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Fri, 13 Jan 2017 23:19:33 +0100 Subject: [PATCH] Remove unnecessary code --- .../java/net/pterodactylus/sone/fcp/AbstractSoneCommand.java | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/main/java/net/pterodactylus/sone/fcp/AbstractSoneCommand.java b/src/main/java/net/pterodactylus/sone/fcp/AbstractSoneCommand.java index 33e9233..3698b05 100644 --- a/src/main/java/net/pterodactylus/sone/fcp/AbstractSoneCommand.java +++ b/src/main/java/net/pterodactylus/sone/fcp/AbstractSoneCommand.java @@ -25,7 +25,6 @@ import net.pterodactylus.sone.data.Post; import net.pterodactylus.sone.data.PostReply; import net.pterodactylus.sone.data.Profile; import net.pterodactylus.sone.data.Profile.Field; -import net.pterodactylus.sone.data.Reply; import net.pterodactylus.sone.data.Sone; import net.pterodactylus.sone.freenet.SimpleFieldSetBuilder; import net.pterodactylus.sone.freenet.fcp.AbstractCommand; @@ -33,12 +32,11 @@ import net.pterodactylus.sone.freenet.fcp.Command; import net.pterodactylus.sone.freenet.fcp.FcpException; import net.pterodactylus.sone.template.SoneAccessor; -import com.google.common.base.Optional; -import com.google.common.collect.Collections2; - import freenet.node.FSParseException; import freenet.support.SimpleFieldSet; +import com.google.common.base.Optional; + /** * Abstract base implementation of a {@link Command} with Sone-related helper * methods. @@ -337,9 +335,6 @@ public abstract class AbstractSoneCommand extends AbstractCommand { for (Post post : posts) { String postPrefix = prefix + postIndex++; postBuilder.put(encodePost(post, postPrefix + ".", includeReplies)); - if (includeReplies) { - postBuilder.put(encodeReplies(Collections2.filter(core.getReplies(post.getId()), Reply.FUTURE_REPLY_FILTER), postPrefix + ".")); - } } return postBuilder.get(); -- 2.7.4