Skip to content

Commit 0af5c94

Browse files
committed
make dev env detection more reliable
1 parent dc27fce commit 0af5c94

File tree

1 file changed

+2
-2
lines changed
  • src/main/java/com/falsepattern/lib/internal

1 file changed

+2
-2
lines changed

src/main/java/com/falsepattern/lib/internal/Share.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
import org.apache.logging.log4j.LogManager;
2828
import org.apache.logging.log4j.Logger;
2929

30-
import net.minecraft.launchwrapper.LaunchClassLoader;
30+
import net.minecraft.launchwrapper.Launch;
3131

3232
import java.io.IOException;
3333

@@ -39,7 +39,7 @@ public final class Share {
3939

4040
static {
4141
try {
42-
val bs = ((LaunchClassLoader) Share.class.getClassLoader()).getClassBytes("net.minecraft.world.World");
42+
val bs = Launch.classLoader.getClassBytes("net.minecraft.world.World");
4343
DEV_ENV = bs != null;
4444
} catch (IOException e) {
4545
throw new RuntimeException(e);

0 commit comments

Comments
 (0)