Commit d71dab5ed49dc2d5edc8193b23a6858ee5c6a7be
1 parent
2ceb8ad8
remove dependency on Util since it doesn't exist server-side
Showing
1 changed file
with
2 additions
and
5 deletions
java/common/com/mumfrey/liteloader/core/LiteLoaderUpdateSite.java
@@ -4,9 +4,6 @@ import java.io.File; | @@ -4,9 +4,6 @@ import java.io.File; | ||
4 | import java.io.IOException; | 4 | import java.io.IOException; |
5 | import java.io.InputStream; | 5 | import java.io.InputStream; |
6 | 6 | ||
7 | -import net.minecraft.util.Util; | ||
8 | -import net.minecraft.util.Util.EnumOS; | ||
9 | - | ||
10 | import com.google.common.io.ByteSink; | 7 | import com.google.common.io.ByteSink; |
11 | import com.google.common.io.Files; | 8 | import com.google.common.io.Files; |
12 | import com.mumfrey.liteloader.launch.ClassPathUtilities; | 9 | import com.mumfrey.liteloader.launch.ClassPathUtilities; |
@@ -166,7 +163,7 @@ public class LiteLoaderUpdateSite extends UpdateSite | @@ -166,7 +163,7 @@ public class LiteLoaderUpdateSite extends UpdateSite | ||
166 | { | 163 | { |
167 | File javaBin = new File(new File(System.getProperty("java.home")), "bin"); | 164 | File javaBin = new File(new File(System.getProperty("java.home")), "bin"); |
168 | File javaWin = new File(javaBin, "javaw.exe"); | 165 | File javaWin = new File(javaBin, "javaw.exe"); |
169 | - | ||
170 | - return Util.getOSType() == EnumOS.WINDOWS && javaWin.isFile() ? javaWin : new File(javaBin, "java"); | 166 | + String osName = System.getProperty("os.name").toLowerCase(); |
167 | + return osName.contains("win") && javaWin.isFile() ? javaWin : new File(javaBin, "java"); | ||
171 | } | 168 | } |
172 | } | 169 | } |