Skip to content

Commit

Permalink
Fix crash on empty dimensions (sftp)
Browse files Browse the repository at this point in the history
  • Loading branch information
Alvinn8 committed Sep 24, 2024
1 parent f664301 commit 98f0297
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ private String getDimensionPath(String dimension) {
public List<RegionFileInfo> getRegionFiles(String dimension) throws IOException {
String path = this.getDimensionPath(dimension) + "/region";

if (this.sftp.statExistence(path) == null) {
return List.of();
}

return this.sftp.ls(path,
file -> file.getName().startsWith("r.") && file.getName().endsWith(".mca")
)
Expand Down

0 comments on commit 98f0297

Please sign in to comment.