mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2024-11-03 01:10:17 +01:00
Sorted nicknames most recent first /player page
This commit is contained in:
parent
004364ca61
commit
03fcd5e893
@ -38,6 +38,7 @@ import com.djrapitops.plan.storage.database.DBSystem;
|
|||||||
import com.djrapitops.plan.storage.database.Database;
|
import com.djrapitops.plan.storage.database.Database;
|
||||||
import com.djrapitops.plan.storage.database.queries.containers.PlayerContainerQuery;
|
import com.djrapitops.plan.storage.database.queries.containers.PlayerContainerQuery;
|
||||||
import com.djrapitops.plan.storage.database.queries.objects.ServerQueries;
|
import com.djrapitops.plan.storage.database.queries.objects.ServerQueries;
|
||||||
|
import com.djrapitops.plan.utilities.comparators.DateHolderRecentComparator;
|
||||||
import org.apache.commons.text.StringEscapeUtils;
|
import org.apache.commons.text.StringEscapeUtils;
|
||||||
|
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
@ -275,6 +276,7 @@ public class PlayerJSONParser {
|
|||||||
Map<UUID, String> serverNames,
|
Map<UUID, String> serverNames,
|
||||||
Formatter<Long> dateFormatter
|
Formatter<Long> dateFormatter
|
||||||
) {
|
) {
|
||||||
|
nicknames.sort(new DateHolderRecentComparator());
|
||||||
List<Nickname> mapped = new ArrayList<>();
|
List<Nickname> mapped = new ArrayList<>();
|
||||||
for (com.djrapitops.plan.delivery.domain.Nickname nickname : nicknames) {
|
for (com.djrapitops.plan.delivery.domain.Nickname nickname : nicknames) {
|
||||||
mapped.add(new Nickname(
|
mapped.add(new Nickname(
|
||||||
|
Loading…
Reference in New Issue
Block a user