Skip to content

Commit 3e26871

Browse files
committed
More fixes for mac installer in gatekeeper.
1 parent b2e2809 commit 3e26871

File tree

1 file changed

+4
-2
lines changed
  • installer/src/main/java/ca/weblite/jdeploy/installer

1 file changed

+4
-2
lines changed

installer/src/main/java/ca/weblite/jdeploy/installer/Main.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,8 +280,9 @@ public static void main(String[] args) {
280280
EventQueue.invokeLater(new Main());
281281
}
282282

283-
283+
private File cachedInstallFilesDir;
284284
private File findInstallFilesDir() {
285+
if (cachedInstallFilesDir != null && cachedInstallFilesDir.exists()) return cachedInstallFilesDir;
285286
System.out.println("findInstallFilesDir():");
286287
if (System.getProperty("client4j.launcher.path") != null) {
287288
System.out.println("Found client4.launcher.path property: "+System.getProperty("client4j.launcher.path"));
@@ -290,7 +291,8 @@ private File findInstallFilesDir() {
290291
System.out.println("client4j.launcher.path is not set");
291292
}
292293
System.out.println("User dir: "+new File(System.getProperty("user.dir")).getAbsolutePath());
293-
return findInstallFilesDir(new File(System.getProperty("user.dir")));
294+
cachedInstallFilesDir = findInstallFilesDir(new File(System.getProperty("user.dir")));
295+
return cachedInstallFilesDir;
294296
}
295297

296298
private File findAppBundle() {

0 commit comments

Comments
 (0)