mirror of
https://github.com/Artillex-Studios/AxMinions.git
synced 2024-11-25 12:05:56 +01:00
Finally fix
This commit is contained in:
parent
6b312bb35f
commit
913efc7fde
@ -376,8 +376,10 @@ class H2DataHandler : DataHandler {
|
||||
|
||||
override fun islandPlace(island: String) {
|
||||
dataSource.connection.use { connection ->
|
||||
connection.prepareStatement("UPDATE `axminions_island_counter` SET `placed` = `placed` + 1 WHERE `island` = ?;").use { statement ->
|
||||
statement.setString(1, island)
|
||||
val placed = getIsland(island) + 1
|
||||
connection.prepareStatement("MERGE INTO `axminions_island_counter`(`placed`, `island`) KEY(`island`) VALUES(?,?);").use { statement ->
|
||||
statement.setInt(1, placed)
|
||||
statement.setString(2, island)
|
||||
statement.executeUpdate()
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user