mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-12-22 16:41:46 +03:00
[FIX] May be NPE
This commit is contained in:
parent
5ba36c3a1c
commit
7e77862cd4
1 changed files with 3 additions and 0 deletions
|
@ -103,6 +103,9 @@ public synchronized static List<JavaVersion> findJava() {
|
|||
}
|
||||
|
||||
private static JavaVersion tryFindJavaByPath(Path path) {
|
||||
if(javaVersionsCache == null) {
|
||||
return null;
|
||||
}
|
||||
for(JavaVersion version : javaVersionsCache) {
|
||||
if(version.jvmDir.equals(path)) {
|
||||
return version;
|
||||
|
|
Loading…
Reference in a new issue