Fixes Deaths & Mob Kills being reversed on sessions fetched from the db.

This commit is contained in:
Rsl1122 2017-08-31 23:38:48 +03:00
parent 74970d26c1
commit f2f090d7e9

View File

@ -179,7 +179,7 @@ public class SessionsTable extends UserIDTable {
int deaths = set.getInt(columnDeaths);
int mobKills = set.getInt(columnMobKills);
List<Session> sessions = sessionsByServer.getOrDefault(serverName, new ArrayList<>());
sessions.add(new Session(id, start, end, deaths, mobKills));
sessions.add(new Session(id, start, end, mobKills, deaths));
sessionsByServer.put(serverName, sessions);
}
return sessionsByServer;
@ -484,7 +484,7 @@ public class SessionsTable extends UserIDTable {
int deaths = set.getInt(columnDeaths);
int mobKills = set.getInt(columnMobKills);
List<Session> sessions = sessionsByUser.getOrDefault(uuid, new ArrayList<>());
sessions.add(new Session(serverID, start, end, deaths, mobKills));
sessions.add(new Session(serverID, start, end, mobKills, deaths));
sessionsByUser.put(uuid, sessions);
}
return sessionsByUser;