Fix allay reload

This commit is contained in:
Zoe Gidiere 2024-10-29 16:13:29 -06:00
parent ef1c9c125f
commit b4ab88a02e

View File

@ -38,9 +38,7 @@ public class AllayPlatform extends AbstractPlatform {
@Override
public boolean reload() {
getTerraConfig().load(this);
getRawConfigRegistry().clear();
try {
getRawConfigRegistry().loadAll(this);
boolean succeed = loadConfigPacks();
GENERATOR_WRAPPERS.forEach(wrapper -> {
getConfigRegistry().get(wrapper.getConfigPack().getRegistryKey()).ifPresent(pack -> {
@ -52,13 +50,8 @@ public class AllayPlatform extends AbstractPlatform {
);
});
});
} catch(Exception e) {
TerraAllayPlugin.INSTANCE.getPluginLogger().error("Failed to reload Terra", e);
return false;
}
return true;
return succeed;
}
@Override