From 187fd3c5c6a1ad65841eef2ba39710ef62137177 Mon Sep 17 00:00:00 2001 From: Isaaku Date: Wed, 24 Jul 2019 13:08:57 -0500 Subject: [PATCH] Network fix --- src/main/java/com/rarchives/ripme/utils/Utils.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/rarchives/ripme/utils/Utils.java b/src/main/java/com/rarchives/ripme/utils/Utils.java index 880e24e8..7cf4625b 100644 --- a/src/main/java/com/rarchives/ripme/utils/Utils.java +++ b/src/main/java/com/rarchives/ripme/utils/Utils.java @@ -222,7 +222,8 @@ public class Utils { } private static File getJarDirectory() { - return new File(System.getProperty("java.class.path")).getParentFile(); + String[] classPath = System.getProperty("java.class.path").split(";"); + return classPath.length > 1 ? new File(System.getProperty("user.dir")) : new File(classPath[0]).getParentFile(); } /**