parent
edb3da4f74
commit
18cec4f88d
|
|
@ -50,7 +50,8 @@ public class ConfigFixer {
|
||||||
this.actualHandler.accept(modConfigEvent);
|
this.actualHandler.accept(modConfigEvent);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
ModernFix.LOGGER.warn("Unable to sync on a {} config object", modConfigEvent.getConfig().getConfigData().getClass().getName());
|
if(modConfigEvent.getConfig().getConfigData() != null)
|
||||||
|
ModernFix.LOGGER.warn("Unable to sync on a {} config object", modConfigEvent.getConfig().getConfigData().getClass().getName());
|
||||||
this.actualHandler.accept(modConfigEvent);
|
this.actualHandler.accept(modConfigEvent);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -85,6 +85,8 @@ public class NightConfigFixer {
|
||||||
private static final Set<Class<?>> UNKNOWN_FILE_CONFIG_CLASSES = Collections.synchronizedSet(new ReferenceOpenHashSet<>());
|
private static final Set<Class<?>> UNKNOWN_FILE_CONFIG_CLASSES = Collections.synchronizedSet(new ReferenceOpenHashSet<>());
|
||||||
|
|
||||||
public static Object toWriteSyncConfig(Object config) {
|
public static Object toWriteSyncConfig(Object config) {
|
||||||
|
if(config == null)
|
||||||
|
return null;
|
||||||
try {
|
try {
|
||||||
if(WRITE_SYNC_CONFIG.isAssignableFrom(config.getClass())) {
|
if(WRITE_SYNC_CONFIG.isAssignableFrom(config.getClass())) {
|
||||||
return config;
|
return config;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user