Fix MFD NPE

This commit is contained in:
Daniel Saukel 2020-04-10 15:49:56 +02:00
parent 0be71908e7
commit 539d3da8a9

View File

@ -131,10 +131,14 @@ public class DungeonConfig extends DREConfig {
ConfigurationSection overrideSection = config.getConfigurationSection("overrideValues"); ConfigurationSection overrideSection = config.getConfigurationSection("overrideValues");
if (overrideSection != null) { if (overrideSection != null) {
overrideValues = new WorldConfig(plugin, overrideSection); overrideValues = new WorldConfig(plugin, overrideSection);
} else {
overrideValues = new WorldConfig(plugin);
} }
ConfigurationSection defaultSection = config.getConfigurationSection("defaultValues"); ConfigurationSection defaultSection = config.getConfigurationSection("defaultValues");
if (defaultValues != null) { if (defaultValues != null) {
defaultValues = new WorldConfig(plugin, defaultSection); defaultValues = new WorldConfig(plugin, defaultSection);
} else {
defaultValues = new WorldConfig(plugin);
} }
} }