mirror of
https://github.com/YouHaveTrouble/CommandWhitelist.git
synced 2026-05-12 06:26:57 +00:00
this can be null
This commit is contained in:
+6
-4
@@ -1,10 +1,12 @@
|
|||||||
package eu.endermite.commandwhitelist.common;
|
package eu.endermite.commandwhitelist.common;
|
||||||
|
|
||||||
|
import org.jetbrains.annotations.Nullable;
|
||||||
|
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
|
|
||||||
public class CWGroup {
|
public class CWGroup {
|
||||||
|
|
||||||
private final String id, permission, custom_command_denied_message;
|
private final String id, permission, commandDeniedMessage;
|
||||||
private final HashSet<String> commands = new HashSet<>();
|
private final HashSet<String> commands = new HashSet<>();
|
||||||
private final HashSet<String> subCommands = new HashSet<>();
|
private final HashSet<String> subCommands = new HashSet<>();
|
||||||
|
|
||||||
@@ -12,7 +14,7 @@ public class CWGroup {
|
|||||||
this.id = id;
|
this.id = id;
|
||||||
this.permission = "commandwhitelist.group." + id;
|
this.permission = "commandwhitelist.group." + id;
|
||||||
this.commands.addAll(commands);
|
this.commands.addAll(commands);
|
||||||
this.custom_command_denied_message = custom_command_denied_message;
|
this.commandDeniedMessage = custom_command_denied_message;
|
||||||
this.subCommands.addAll(subCommands);
|
this.subCommands.addAll(subCommands);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -28,8 +30,8 @@ public class CWGroup {
|
|||||||
return commands;
|
return commands;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getCustomCommandDeniedMessage() {
|
public @Nullable String getCommandDeniedMessage() {
|
||||||
return custom_command_denied_message;
|
return commandDeniedMessage;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void addCommand(String command) {
|
public void addCommand(String command) {
|
||||||
|
|||||||
Reference in New Issue
Block a user