Return the processed modlist data to the upstream system, not the raw unprocessed data. Should resolve the problem

that mixin complains about missing info when it's in a "crashed" situation.

Signed-off-by: cpw <cpw+github@weeksfamily.ca>
This commit is contained in:
cpw 2020-11-13 19:12:33 -05:00
parent 0ff8a596fc
commit 4a09a2420d
No known key found for this signature in database
GPG key ID: 8EB3DF749553B1B7

View file

@ -34,6 +34,7 @@ import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.fml.loading.moddiscovery.BackgroundScanHandler;
import net.minecraftforge.fml.loading.moddiscovery.ModDiscoverer;
import net.minecraftforge.fml.loading.moddiscovery.ModFile;
import net.minecraftforge.fml.loading.moddiscovery.ModFileInfo;
import net.minecraftforge.fml.loading.progress.EarlyProgressVisualization;
import net.minecraftforge.fml.loading.progress.StartupMessageManager;
import net.minecraftforge.forgespi.Environment;
@ -53,6 +54,7 @@ import java.util.Map;
import java.util.Optional;
import java.util.Set;
import java.util.function.BiFunction;
import java.util.function.Function;
import java.util.function.Predicate;
import java.util.stream.Collectors;
@ -214,7 +216,7 @@ public class FMLLoader
loadingModList = backgroundScanHandler.getLoadingModList();
commonLaunchHandler.addLibraries(backgroundScanHandler.getModFiles().getOrDefault(IModFile.Type.LIBRARY, Collections.emptyList()));
progressWindowTick.run();
return backgroundScanHandler.getModFiles();
return loadingModList.getModFiles().stream().map(ModFileInfo::getFile).collect(Collectors.groupingBy(ModFile::getType));
}
public static ICoreModProvider getCoreModProvider() {