registerCommand can be private as it isn't used outside of the class
Reverted the last commit
This commit is contained in:
parent
6fc6298b57
commit
b24462e55c
@ -37,7 +37,7 @@ public class MuteCommand extends Command {
|
||||
MessageFactory.create("Could not find member!").setColor(member.getColor()).queue(channel);
|
||||
return;
|
||||
}
|
||||
Member targetMember = (Member) objArray[0];
|
||||
Member targetMember = (Member) objArray[1];
|
||||
String targetMemberName = String.valueOf(objArray[0]);
|
||||
if (targetMember == null) {
|
||||
MessageFactory.create("Could not find member!").setColor(member.getColor()).queue(channel);
|
||||
|
@ -10,7 +10,8 @@ public class CommandHandler {
|
||||
|
||||
private Map<String, Command> commandMap = new HashMap<>();
|
||||
|
||||
public void registerCommand(Command command) {
|
||||
|
||||
private void registerCommand(Command command) {
|
||||
if (commandMap.containsKey(command.getCommand())) return;
|
||||
commandMap.put(command.getCommand(), command);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user