Skip to content

Commit

Permalink
fix npe
Browse files Browse the repository at this point in the history
  • Loading branch information
flipatlas committed Dec 9, 2024
1 parent c181728 commit 2169154
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,10 @@ private File getProvidedNodeDirectory() {
if (!isNull(configuredNodeDirectory) && configuredNodeDirectory.exists()) return configuredNodeDirectory;

String systemNodeDirectoryPath = System.getenv("AFMP_INSTALLED_NODE_DIRECTORY");
File systemNodeDirectory = new File(systemNodeDirectoryPath);
if (systemNodeDirectory.exists()) return systemNodeDirectory;
if (!isNull(systemNodeDirectoryPath)) {
File systemNodeDirectory = new File(systemNodeDirectoryPath);
if (systemNodeDirectory.exists()) return systemNodeDirectory;
}

return null;
}
Expand Down

0 comments on commit 2169154

Please sign in to comment.