Use an immutable view in GeyserDefineCommandsEvent

Methods to properly register/unregister commands are provided in the command manager
This commit is contained in:
RednedEpic 2022-07-02 12:30:23 -05:00
parent 36c49a7256
commit b5eb27693f
2 changed files with 2 additions and 3 deletions

View file

@ -70,7 +70,7 @@ public abstract class GeyserCommandManager extends CommandManager {
register(new StopCommand(geyser, "stop", "geyser.commands.stop.desc", "geyser.command.stop"));
}
this.geyser.eventBus().fire(new GeyserDefineCommandsEvent(this, this.commands));
this.geyser.eventBus().fire(new GeyserDefineCommandsEvent(this, this.commands()));
}
@Override