Commit 84ea1ab37398864896ca97183a26dd27a2026ce9

Authored by Mumfrey
1 parent c65f1431

Fix incorrect order for injecting a mixin container with Mixin 0.5.6

src/main/java/com/mumfrey/liteloader/core/LiteLoaderEnumerator.java
@@ -640,13 +640,17 @@ public class LiteLoaderEnumerator implements LoaderEnumerator @@ -640,13 +640,17 @@ public class LiteLoaderEnumerator implements LoaderEnumerator
640 { 640 {
641 try 641 try
642 { 642 {
  643 + if (container.hasMixins())
  644 + {
  645 + this.injectContainerRecursive(container);
  646 + }
  647 +
643 for (String config : container.getMixinConfigs()) 648 for (String config : container.getMixinConfigs())
644 { 649 {
645 if (config.endsWith(".json")) 650 if (config.endsWith(".json"))
646 { 651 {
647 LiteLoaderLogger.info(Verbosity.REDUCED, "Registering mixin config %s for %s", config, container.getName()); 652 LiteLoaderLogger.info(Verbosity.REDUCED, "Registering mixin config %s for %s", config, container.getName());
648 Mixins.addConfiguration(config); 653 Mixins.addConfiguration(config);
649 - this.injectContainerRecursive(container);  
650 } 654 }
651 else if (config.contains(".json@")) 655 else if (config.contains(".json@"))
652 { 656 {
@@ -660,7 +664,6 @@ public class LiteLoaderEnumerator implements LoaderEnumerator @@ -660,7 +664,6 @@ public class LiteLoaderEnumerator implements LoaderEnumerator
660 LiteLoaderLogger.warning("%s specifies mixin environment in metadata which is deprecated, use config instead", 664 LiteLoaderLogger.warning("%s specifies mixin environment in metadata which is deprecated, use config instead",
661 container.getName()); 665 container.getName());
662 MixinEnvironment.getEnvironment(phase).addConfiguration(config); 666 MixinEnvironment.getEnvironment(phase).addConfiguration(config);
663 - this.injectContainerRecursive(container);  
664 } 667 }
665 } 668 }
666 } 669 }