Use our fork's removeChildByName

This commit is contained in:
Andrew Steinborn
2020-11-16 12:24:14 -05:00
parent 218b24024f
commit aadd79e62b

View File

@@ -125,11 +125,7 @@ public class VelocityCommandManager implements CommandManager {
@Override
public void unregister(final String alias) {
Preconditions.checkNotNull(alias, "alias");
CommandNode<CommandSource> node =
dispatcher.getRoot().getChild(alias.toLowerCase(Locale.ENGLISH));
if (node != null) {
dispatcher.getRoot().getChildren().remove(node);
}
dispatcher.getRoot().removeChildByName(alias.toLowerCase(Locale.ENGLISH));
}
/**