X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2FSearchPage.java;h=6e10b249adf7b5c2c7c4490d5f0b96c6af3bfb1a;hp=91e2a0882438b109b926a5a2edbb13a58833043c;hb=a8d443ca97ae7a9707b19bfd90cb521cf02b106c;hpb=45f92ec63dbf8134d92ceed67294faa38117b195 diff --git a/src/main/java/net/pterodactylus/sone/web/SearchPage.java b/src/main/java/net/pterodactylus/sone/web/SearchPage.java index 91e2a08..6e10b24 100644 --- a/src/main/java/net/pterodactylus/sone/web/SearchPage.java +++ b/src/main/java/net/pterodactylus/sone/web/SearchPage.java @@ -28,6 +28,7 @@ import java.util.logging.Level; import java.util.logging.Logger; 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; @@ -66,6 +67,7 @@ public class SearchPage extends SoneTemplatePage { /** Short-term cache. */ private final Cache, Set>> hitCache = new MemoryCache, Set>>(new ValueRetriever, Set>>() { + @Override @SuppressWarnings("synthetic-access") public CacheItem>> retrieve(List phrases) throws CacheException { Set posts = new HashSet(); @@ -365,7 +367,7 @@ public class SearchPage extends SoneTemplatePage { if (post.getRecipient() != null) { postString.append(' ').append(SoneStringGenerator.NAME_GENERATOR.generateString(post.getRecipient())); } - for (Reply reply : Filters.filteredList(webInterface.getCore().getReplies(post), Reply.FUTURE_REPLIES_FILTER)) { + for (PostReply reply : Filters.filteredList(webInterface.getCore().getReplies(post), Reply.FUTURE_REPLY_FILTER)) { postString.append(' ').append(SoneStringGenerator.NAME_GENERATOR.generateString(reply.getSone())); postString.append(' ').append(reply.getText()); }