mirror of
https://github.com/YouHaveTrouble/CommandWhitelist.git
synced 2026-05-12 06:26:57 +00:00
fix format
This commit is contained in:
+3
-6
@@ -2,14 +2,11 @@ package eu.endermite.commandwhitelist.common;
|
||||
|
||||
import org.yaml.snakeyaml.DumperOptions;
|
||||
import org.yaml.snakeyaml.Yaml;
|
||||
|
||||
import java.io.*;
|
||||
import java.util.*;
|
||||
|
||||
public class ConfigCache {
|
||||
|
||||
//TODO probably rewrite this yet again
|
||||
|
||||
private final File configFile;
|
||||
private final boolean canDoProtocolLib;
|
||||
private final HashMap<String, CWGroup> groupList = new LinkedHashMap<>();
|
||||
@@ -93,7 +90,7 @@ public class ConfigCache {
|
||||
this.config_reloaded = messages.get("config_reloaded");
|
||||
this.added_to_whitelist = messages.get("added_to_whitelist");
|
||||
this.removed_from_whitelist = messages.get("removed_from_whitelist");
|
||||
this.group_doesnt_exist = messages.get("group_doesnt-exist");
|
||||
this.group_doesnt_exist = messages.get("group_doesnt_exist");
|
||||
this.subcommand_denied = messages.get("subcommand_denied");
|
||||
|
||||
if (canDoProtocolLib)
|
||||
@@ -129,8 +126,8 @@ public class ConfigCache {
|
||||
messages.put("no_permission", stringOrDefault(no_permission, "<red>You don't have permission to do this."));
|
||||
messages.put("no_such_subcommand", stringOrDefault(no_such_subcommand, "<red>No subcommand by that name."));
|
||||
messages.put("config_reloaded", stringOrDefault(config_reloaded, "<yellow>Configuration reloaded."));
|
||||
messages.put("added_to_whitelist", stringOrDefault(added_to_whitelist, "<yellow>Whitelisted command <orange>%s <yellow>for permission <orange>%s"));
|
||||
messages.put("removed_from_whitelist", stringOrDefault(removed_from_whitelist, "<yellow>Removed command <orange>%s <yellow>from permission <orange>%s"));
|
||||
messages.put("added_to_whitelist", stringOrDefault(added_to_whitelist, "<yellow>Whitelisted command <gold>%s <yellow>for permission <gold>%s"));
|
||||
messages.put("removed_from_whitelist", stringOrDefault(removed_from_whitelist, "<yellow>Removed command <gold>%s <yellow>from permission <gold>%s"));
|
||||
messages.put("group_doesnt_exist", stringOrDefault(group_doesnt_exist, "<red>Group doesn't exist or error occured"));
|
||||
return messages;
|
||||
}
|
||||
|
||||
-2
@@ -1,6 +1,5 @@
|
||||
package eu.endermite.commandwhitelist.common.commands;
|
||||
|
||||
import com.mojang.brigadier.tree.LiteralCommandNode;
|
||||
import eu.endermite.commandwhitelist.common.CWGroup;
|
||||
import eu.endermite.commandwhitelist.common.ConfigCache;
|
||||
import net.kyori.adventure.text.Component;
|
||||
@@ -9,7 +8,6 @@ import net.kyori.adventure.text.format.NamedTextColor;
|
||||
import net.kyori.adventure.text.format.TextDecoration;
|
||||
import net.kyori.adventure.text.minimessage.MiniMessage;
|
||||
|
||||
|
||||
public class CWCommand {
|
||||
|
||||
public static boolean addToWhitelist(ConfigCache configCache, String command, String group) {
|
||||
|
||||
Reference in New Issue
Block a user