mirror of
https://github.com/2006-Scape/Parabot.git
synced 2026-07-07 00:38:16 +00:00
Merge pull request #174 from Parabot/bugfix/folder-location
[BUGFIX] Removed user.home property
This commit is contained in:
@@ -26,14 +26,12 @@ public class SystemRedirect {
|
|||||||
public static String getProperty(String s) {
|
public static String getProperty(String s) {
|
||||||
String value;
|
String value;
|
||||||
switch (s) {
|
switch (s) {
|
||||||
case "user.home":
|
|
||||||
value = Directories.getCachePath().getAbsolutePath();
|
|
||||||
break;
|
|
||||||
case "java.class.path":
|
case "java.class.path":
|
||||||
value = ".";
|
value = ".";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
value = System.getProperty(s);
|
value = System.getProperty(s);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
System.out.printf("GetSystemProp %s = %s\n", s, value);
|
System.out.printf("GetSystemProp %s = %s\n", s, value);
|
||||||
return value;
|
return value;
|
||||||
@@ -42,9 +40,6 @@ public class SystemRedirect {
|
|||||||
public static String getProperty(String s, String s2) {
|
public static String getProperty(String s, String s2) {
|
||||||
String value = null;
|
String value = null;
|
||||||
switch (s2) {
|
switch (s2) {
|
||||||
case "user.home":
|
|
||||||
value = Directories.getCachePath().getAbsolutePath();
|
|
||||||
break;
|
|
||||||
case "java.class.path":
|
case "java.class.path":
|
||||||
value = ".";
|
value = ".";
|
||||||
break;
|
break;
|
||||||
@@ -52,14 +47,12 @@ public class SystemRedirect {
|
|||||||
|
|
||||||
if (value == null) {
|
if (value == null) {
|
||||||
switch (s) {
|
switch (s) {
|
||||||
case "user.home":
|
|
||||||
value = Directories.getCachePath().getAbsolutePath();
|
|
||||||
break;
|
|
||||||
case "java.class.path":
|
case "java.class.path":
|
||||||
value = ".";
|
value = ".";
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
value = System.getProperty(s);
|
value = System.getProperty(s);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
System.out.printf("GetSystemProp %s = %s\n", s, value);
|
System.out.printf("GetSystemProp %s = %s\n", s, value);
|
||||||
|
|||||||
Reference in New Issue
Block a user