[1.18] Make ConfigValue implement Supplier. (#8777)

This commit is contained in:
King Lemming authored and GitHub committed 2022-06-20 23:08:24 +01:00
1 parent be0facc2aa
commit 1a46f205d6
1 file changed
+2 -1
@@ -810,7 +810,7 @@ public class ForgeConfigSpec extends UnmodifiableConfigWrapper<UnmodifiableConfi
}
}
public static class ConfigValue<T>
public static class ConfigValue<T> implements Supplier<T>
{
private static boolean USE_CACHES = true;
@@ -835,6 +835,7 @@ public class ForgeConfigSpec extends UnmodifiableConfigWrapper<UnmodifiableConfi
return Lists.newArrayList(path);
}
@Override
public T get()
{
Preconditions.checkNotNull(spec, "Cannot get config value before spec is built");