Skip to content

Commit

Permalink
convert to parent dir before returning
Browse files Browse the repository at this point in the history
  • Loading branch information
JuicyDragon committed Mar 18, 2024
1 parent bb44bde commit c16a578
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public Collection<File> findCaseDirectories(File rootSearchDirectory) {
for (int i = 0; i < children.length; i++) {
File child = children[i];
if(child.isFile() && child.getName().equalsIgnoreCase("case.fbi2")) {
return List.of(child);
return List.of(child.getParentFile());
}
}

Expand All @@ -61,7 +61,7 @@ public Collection<File> findCaseDirectories(File rootSearchDirectory) {
}
}
}
return result;
return result.stream().map(File::getParentFile).collect(Collectors.toList());
}
}

Expand Down

0 comments on commit c16a578

Please sign in to comment.