Skip to content

Commit

Permalink
Ignore cancelled chat message events
Browse files Browse the repository at this point in the history
Improves compatibility with chat filters
  • Loading branch information
jorgeberrex committed Sep 22, 2024
1 parent c058893 commit 10772d1
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ class ChatListener : Listener {
sendAdminChat(PGM.get().matchManager.getMatch(), prefix, player.name, message, serverId)
}

@EventHandler
@EventHandler(ignoreCancelled = true)
fun onPlayerChat(event: AsyncPlayerChatEvent) = runBlocking {
val player = event.player
val context = PlayerManager.getPlayer(player.uniqueId)!!
Expand Down

0 comments on commit 10772d1

Please sign in to comment.