diff --git a/README.md b/README.md index 525874e..d25e42b 100644 --- a/README.md +++ b/README.md @@ -51,9 +51,9 @@ repositories { dependencies { // 对于 Bukkit 插件 - compileOnly("cn.hamster3.mc.plugin:ball-bukkit:1.5.3") + compileOnly("cn.hamster3.mc.plugin:ball-bukkit:1.5.7") // 对于 BungeeCord 插件 - compileOnly("cn.hamster3.mc.plugin:ball-bungee:1.5.3") + compileOnly("cn.hamster3.mc.plugin:ball-bungee:1.5.7") } ``` @@ -79,13 +79,13 @@ dependencies { cn.hamster3.mc.plugin ball-bukkit - 1.5.3 + 1.5.7 cn.hamster3.mc.plugin ball-bungee - 1.5.3 + 1.5.7 diff --git a/ball-common/src/main/java/cn/hamster3/mc/plugin/ball/common/api/BallAPI.java b/ball-common/src/main/java/cn/hamster3/mc/plugin/ball/common/api/BallAPI.java index c048ee9..f8837cf 100644 --- a/ball-common/src/main/java/cn/hamster3/mc/plugin/ball/common/api/BallAPI.java +++ b/ball-common/src/main/java/cn/hamster3/mc/plugin/ball/common/api/BallAPI.java @@ -128,11 +128,11 @@ public abstract class BallAPI { } } if (getBallConfig().isGameServerUpdatePlayerInfo()) { - try (PreparedStatement statement = connection.prepareStatement( - "SELECT * FROM `hamster_ball_player_info` WHERE `proxy_server` IN (?);" - )) { - statement.setString(1, String.join(",", getBallConfig().getLoadPlayerInfoFilter())); - try (ResultSet set = statement.executeQuery()) { + try (Statement statement = connection.createStatement()) { + try (ResultSet set = statement.executeQuery(String.format( + "SELECT * FROM `hamster_ball_player_info` WHERE `proxy_server` IN ('%s');", + String.join("', '", getBallConfig().getLoadPlayerInfoFilter()) + ))) { while (set.next()) { UUID uuid = UUID.fromString(set.getString("uuid")); allPlayerInfo.put(uuid, new BallPlayerInfo(uuid, diff --git a/build.gradle.kts b/build.gradle.kts index fbb253a..5e7e8a2 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -5,7 +5,7 @@ plugins { } group = "cn.hamster3.mc.plugin" -version = "1.5.6" +version = "1.5.7" subprojects { apply {