Router: Cleanup fix for gitlab ticket #16

Only check for clients.config if there was no clients.config.d
This commit is contained in:
zzz
2021-04-27 10:58:17 -04:00
parent 9f23102428
commit 20c528debe

View File

@@ -99,11 +99,13 @@ public class WorkingDir {
// then attempt to use, resulting in a router with no client applications. Checking
// for clients.config.d determines if the directory is "Real" or not.
File clientAppsConfig = new File(checkOld.getAbsolutePath(), "clients.config.d");
if (routerConfig.exists() && clientAppsConfig.exists() && clientAppsConfig.isDirectory())
home = appdata;
clientAppsConfig = new File(checkOld.getAbsolutePath(), "clients.config");
if (routerConfig.exists() && clientAppsConfig.exists())
if (routerConfig.exists() && clientAppsConfig.exists() && clientAppsConfig.isDirectory()) {
home = appdata;
} else {
clientAppsConfig = new File(checkOld.getAbsolutePath(), "clients.config");
if (routerConfig.exists() && clientAppsConfig.exists())
home = appdata;
}
}
}
dirf = new SecureDirectory(home, WORKING_DIR_DEFAULT_WINDOWS);