aboutsummaryrefslogtreecommitdiff
path: root/spark-fabric/src
diff options
context:
space:
mode:
Diffstat (limited to 'spark-fabric/src')
-rw-r--r--spark-fabric/src/main/java/me/lucko/spark/fabric/FabricClassSourceLookup.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/spark-fabric/src/main/java/me/lucko/spark/fabric/FabricClassSourceLookup.java b/spark-fabric/src/main/java/me/lucko/spark/fabric/FabricClassSourceLookup.java
index 0ad05b9..ef22d9c 100644
--- a/spark-fabric/src/main/java/me/lucko/spark/fabric/FabricClassSourceLookup.java
+++ b/spark-fabric/src/main/java/me/lucko/spark/fabric/FabricClassSourceLookup.java
@@ -142,7 +142,8 @@ public class FabricClassSourceLookup extends ClassSourceLookup.ByCodeSource {
private static String modIdFromMixinClass(String mixinClassName) {
for (Config config : MixinUtils.getMixinConfigs().values()) {
IMixinConfig mixinConfig = config.getConfig();
- if (mixinClassName.startsWith(mixinConfig.getMixinPackage())) {
+ String mixinPackage = mixinConfig.getMixinPackage();
+ if (!mixinPackage.isEmpty() && mixinClassName.startsWith(mixinPackage)) {
return mixinConfig.getDecoration(FabricUtil.KEY_MOD_ID);
}
}