Add prefixes to all encoding methods, add method to encode a single Post.
[Sone.git] / src / main / java / net / pterodactylus / sone / fcp / GetPostFeedCommand.java
index f1ff9a8..895c1c6 100644 (file)
@@ -73,10 +73,10 @@ public class GetPostFeedCommand extends AbstractSoneCommand {
                Collections.sort(sortedPosts, Post.TIME_COMPARATOR);
 
                if (sortedPosts.size() < startPost) {
-                       return new Response(encodePosts(Collections.<Post> emptyList(), false));
+                       return new Response(encodePosts(Collections.<Post> emptyList(), "Posts.", false));
                }
 
-               return new Response(encodePosts(sortedPosts.subList(startPost, (maxPosts == -1) ? sortedPosts.size() : Math.min(startPost + maxPosts, sortedPosts.size())), true));
+               return new Response(encodePosts(sortedPosts.subList(startPost, (maxPosts == -1) ? sortedPosts.size() : Math.min(startPost + maxPosts, sortedPosts.size())), "Posts.", true));
        }
 
 }