Disabling mcMMO when the config breaks is dumb

Fixes #4732
This commit is contained in:
nossr50 2022-01-30 14:24:21 -08:00
parent 8f0fb76847
commit 86e7bfbf89
2 changed files with 1 additions and 10 deletions

View File

@ -99,9 +99,7 @@ public abstract class BukkitConfig {
if (validateKeys()) { if (validateKeys()) {
mcMMO.p.debug("No errors found in " + fileName + "!"); mcMMO.p.debug("No errors found in " + fileName + "!");
} else { } else {
mcMMO.p.getLogger().warning("Errors were found in " + fileName + "! mcMMO was disabled!"); mcMMO.p.getLogger().warning("Errors were found in " + fileName + ", overwriting invalid values!");
mcMMO.p.getServer().getPluginManager().disablePlugin(mcMMO.p);
mcMMO.p.noErrorsInConfigFiles = false;
} }
} }

View File

@ -125,9 +125,6 @@ public class mcMMO extends JavaPlugin {
// API checks // API checks
private static boolean serverAPIOutdated = false; private static boolean serverAPIOutdated = false;
// Config Validation Check
public boolean noErrorsInConfigFiles = true;
// XP Event Check // XP Event Check
private boolean xpEventEnabled; private boolean xpEventEnabled;
@ -199,10 +196,6 @@ public class mcMMO extends JavaPlugin {
loadConfigFiles(); loadConfigFiles();
if (!noErrorsInConfigFiles) {
return;
}
if (getServer().getName().equals("Cauldron") || getServer().getName().equals("MCPC+")) { if (getServer().getName().equals("Cauldron") || getServer().getName().equals("MCPC+")) {
checkModConfigs(); checkModConfigs();
} }