mirror of
https://github.com/PaperMC/Velocity.git
synced 2026-02-17 14:37:43 +01:00
Actually fix accidental breaking change not allowing aliases to be overridden.
This commit is contained in:
@@ -112,6 +112,11 @@ public class VelocityCommandManager implements CommandManager {
|
||||
dispatcher.getRoot().addChild(node);
|
||||
while (aliasIterator.hasNext()) {
|
||||
String otherAlias = aliasIterator.next();
|
||||
CommandNode<CommandSource> existingNode = dispatcher.getRoot()
|
||||
.getChild(alias.toLowerCase(Locale.ENGLISH));
|
||||
if (existingNode != null) {
|
||||
dispatcher.getRoot().getChildren().remove(existingNode);
|
||||
}
|
||||
dispatcher.getRoot().addChild(BrigadierUtils.buildRedirect(otherAlias, node));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user