Fixed bug where staff picks would not appear after someone searched in public rooms

This commit is contained in:
ArpyAge 2022-09-17 01:36:34 +02:00
parent bb6a2e5eac
commit b6f3214cc8

View File

@ -88,7 +88,12 @@ public class RequestNewNavigatorRoomsEvent extends MessageHandler {
return; return;
try { try {
List<SearchResultList> resultLists = new ArrayList<>(filter.getResult(this.client.getHabbo(), field, part, category != null ? category.getId() : -1)); List<SearchResultList> resultLists2 = filter.getResult(this.client.getHabbo(), field, part, category != null ? category.getId() : -1);
List<SearchResultList> resultLists = new ArrayList<>();
for(SearchResultList searchResultList : resultLists2) {
List<Room> rooms = (ArrayList)((ArrayList)searchResultList.rooms).clone();
resultLists.add(new SearchResultList(searchResultList.order, searchResultList.code, searchResultList.query, searchResultList.action, searchResultList.mode, searchResultList.hidden, rooms, searchResultList.filter, searchResultList.showInvisible, searchResultList.displayOrder, searchResultList.categoryOrder));
}
filter.filter(field.field, part, resultLists); filter.filter(field.field, part, resultLists);
resultLists = toQueryResults(resultLists); resultLists = toQueryResults(resultLists);
this.client.sendResponse(new NewNavigatorSearchResultsComposer(view, query, resultLists)); this.client.sendResponse(new NewNavigatorSearchResultsComposer(view, query, resultLists));