When checking whether to use Roaming appdata(like on older installs or on installs where people deliberately use Roaming appdata) also check whether clients.config exists and if it does, set home to Roaming appdata since people may be updating from routers before the migration to clients.config.d directories. This should fix #16

This commit is contained in:
idk
2021-04-22 23:27:31 -04:00
parent f62c748342
commit 025445fc65

View File

@@ -101,6 +101,9 @@ public class WorkingDir {
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())
home = appdata;
}
}
dirf = new SecureDirectory(home, WORKING_DIR_DEFAULT_WINDOWS);