fix command registration error

This commit is contained in:
Lennart ten wolde 2017-02-26 20:08:20 +01:00
parent 0b4507c4a6
commit c7c85c1a93
1 changed files with 1 additions and 3 deletions

View File

@ -32,9 +32,7 @@ public abstract class Command {
public Command(Marriage marriage, String command, String... aliases) {
this.marriage = marriage;
this.aliases = Lists.asList(command, aliases).toArray(new String[0]);
if(this.aliases.length > 0) {
this.permission = Permissions.getByNode("marry." + aliases[0]);
}
this.permission = Permissions.getByNode("marry." + command);
}
public abstract void execute();