mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-13 16:54:22 +00:00
Co-authored-by: J-RAP <SrRapero720@hotmail.com>
This commit is contained in:
1 parent
921771bd11
commit
1b0360928f
1 file changed
+1
-1
@@ -346,7 +346,7 @@ public class ForgeConfigSpec extends UnmodifiableConfigWrapper<UnmodifiableConfi
|
||||
return defineInList(path, () -> defaultValue, acceptableValues);
|
||||
}
|
||||
public <T> ConfigValue<T> defineInList(List<String> path, Supplier<T> defaultSupplier, Collection<? extends T> acceptableValues) {
|
||||
return define(path, defaultSupplier, acceptableValues::contains);
|
||||
return define(path, defaultSupplier, o -> o != null && acceptableValues.contains(o));
|
||||
}
|
||||
public <T> ConfigValue<List<? extends T>> defineList(String path, List<? extends T> defaultValue, Predicate<Object> elementValidator) {
|
||||
return defineList(split(path), defaultValue, elementValidator);
|
||||
|
||||
Reference in new issue
Block a user