Sanitize Bukkit Command Label Before Passing On (#149)

Fixes #146 

This might not be the 100% perfect method for fixing this, but as it stands, it's the least amount of diff
 needed to fix said issue.
This commit is contained in:
willies952002
2018-07-04 01:27:01 -04:00
committed by Daniel Ennis
parent 422238b477
commit 786ebe831f
2 changed files with 2 additions and 0 deletions
+1
View File
@@ -10,3 +10,4 @@ If you open a PR and are not already in this file, please feel free to add yours
* [***kashike***](https://github.com/aikar/commands/commits?author=kashike) - Sponge Support, Random nit picks
* [***Williambraecky***](https://github.com/aikar/commands/commits?author=Williambraecky) - BungeeCord Support
* [***dumptruckman***](https://github.com/aikar/commands/commits?author=dumptruckman) - JDA Support
* [***willies952002***](https://github.com/aikar/commands/commits?author=willies952002)
@@ -60,6 +60,7 @@ public class BukkitRootCommand extends Command implements RootCommand {
@Override
public boolean execute(CommandSender sender, String commandLabel, String[] args) {
if (commandLabel.contains(":")) commandLabel = ACFPatterns.COLON.split(commandLabel, 2)[1];
execute(manager.getCommandIssuer(sender), commandLabel, args);
return true;
}