[Forge installer 1.12+] Additional checks

Now launcer would read from /version.json by default if field is null
This commit is contained in:
ArtDev 2020-11-23 18:51:53 +03:00 committed by GitHub
parent 3f88a4b8d1
commit 1aa0ee5e99
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,7 +29,7 @@ public class NewForgeInstaller extends BaseInstaller {
ctx.appendlnToLog("Writing " + target);
Tools.write(
target,
Tools.convertStream(mJarFile.getInputStream(mJarFile.getEntry(profile.json)))
Tools.convertStream(mJarFile.getInputStream(mJarFile.getEntry(profile.json==null ? "/version.json" : profile.json)))
);
// Forge 1.12.2+ installer does not include universal, so download