diff --git a/Plugins/Mineplex.Core/src/mineplex/core/elo/EloRepository.java b/Plugins/Mineplex.Core/src/mineplex/core/elo/EloRepository.java index 713d76f81..2bd9686e1 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/elo/EloRepository.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/elo/EloRepository.java @@ -11,7 +11,7 @@ import org.bukkit.plugin.java.JavaPlugin; public class EloRepository extends MinecraftRepository { - private static String INSERT_ELO = "INSERT INTO eloRating (accountId, gameType) VALUES (?, ?);"; + private static String INSERT_ELO = "INSERT INTO eloRating (accountId, gameType, elo) VALUES (?, ?, ?);"; private static String UPDATE_ELO = "UPDATE eloRating SET elo=? WHERE accountId = ? AND gameType = ?;"; public EloRepository(JavaPlugin plugin) @@ -27,7 +27,7 @@ public class EloRepository extends MinecraftRepository { if (executeUpdate(UPDATE_ELO, new ColumnInt("elo", elo), new ColumnInt("accountId", accountId), new ColumnInt("gameType", gameType)) > 0) return true; - else if (executeUpdate(INSERT_ELO, new ColumnInt("elo", elo), new ColumnInt("accountId", accountId), new ColumnInt("gameType", gameType)) > 0) + else if (executeUpdate(INSERT_ELO, new ColumnInt("accountId", accountId), new ColumnInt("gameType", gameType), new ColumnInt("elo", elo)) > 0) return true; return false;