mirror of
https://github.com/LegacyModdingMC/UniMix.git
synced 2026-11-27 05:03:09 +00:00
Use service ClassProvider instead of Class.forName for refmap wrappers
This commit is contained in:
1 parent
dcc124d487
commit
828f9943f5
1 file changed
+1
-1
@@ -729,7 +729,7 @@ final class MixinConfig implements Comparable<MixinConfig>, IMixinConfig {
|
||||
String wrapperName = this.mixinPackage + this.refMapperWrapper;
|
||||
try {
|
||||
@SuppressWarnings("unchecked")
|
||||
Class<IReferenceMapper> wrapperCls = (Class<IReferenceMapper>) Class.forName(wrapperName);
|
||||
Class<IReferenceMapper> wrapperCls = (Class<IReferenceMapper>) this.service.getClassProvider().findClass(wrapperName, true);
|
||||
Constructor<IReferenceMapper> ctr = wrapperCls.getConstructor(MixinEnvironment.class, IReferenceMapper.class);
|
||||
this.refMapper = ctr.newInstance(this.env, this.refMapper);
|
||||
} catch (ClassNotFoundException e) {
|
||||
|
||||
Reference in new issue
Block a user