mirror of
https://github.com/PaperMC/Velocity.git
synced 2025-01-18 14:44:07 +08:00
Add logging to command executions by players
This commit is contained in:
parent
21ad6a433f
commit
a9df92d308
@ -129,6 +129,9 @@ public class ClientPlaySessionHandler implements MinecraftSessionHandler {
|
||||
server.getCommandManager().callCommandEvent(player, msg.substring(1))
|
||||
.thenComposeAsync(event -> processCommandExecuteResult(originalCommand,
|
||||
event.getResult()))
|
||||
.whenCompleteAsync((ignored, throwable) -> {
|
||||
logger.info("{} -> executed command /{}", player.getUsername(), originalCommand);
|
||||
})
|
||||
.exceptionally(e -> {
|
||||
logger.info("Exception occurred while running command for {}",
|
||||
player.getUsername(), e);
|
||||
|
Loading…
Reference in New Issue
Block a user