Skip to content

Commit

Permalink
Fixed missing updating logic.
Browse files Browse the repository at this point in the history
  • Loading branch information
EncryptSL committed Aug 26, 2024
1 parent e5c1a97 commit cecf9eb
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class DatabaseEcoModel : PlayerSQL {
try {
val table = Account(currency)
table.update ({ table.uuid eq uuid }) {
it[table.username] = username
}
} catch (e : ExposedSQLException) {
LiteEco.instance.logger.severe(e.message ?: e.localizedMessage)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ class AccountManageListener(private val liteEco: LiteEco) : Listener {
for (currency in liteEco.currencyImpl.getCurrenciesKeys()) {
liteEco.databaseEcoModel.getUserByUUID(player.uniqueId, currency).thenApply {
liteEco.databaseEcoModel.updatePlayerName(it.uuid, player.name.toString(), currency)

return@thenApply it
}.thenAccept {
liteEco.api.cacheAccount(player, currency, it.money)
Expand Down

0 comments on commit cecf9eb

Please sign in to comment.