We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0042820 commit bdf150cCopy full SHA for bdf150c
src/main/java/dev/jbang/devkitman/JdkManager.java
@@ -601,7 +601,11 @@ public void removeDefaultJdk() {
601
}
602
603
public boolean isCurrentJdkManaged() {
604
- Path currentJdk = Paths.get(System.getProperty("java.home"));
+ String jh = System.getProperty("java.home");
605
+ if (jh == null) {
606
+ return false;
607
+ }
608
+ Path currentJdk = Paths.get(jh);
609
return providers(JdkProvider.Predicates.canUpdate)
610
.anyMatch(p -> p.getInstalledByPath(currentJdk) != null);
611
0 commit comments