Skip to content

Commit

Permalink
Fix #16816.
Browse files Browse the repository at this point in the history
  • Loading branch information
dkocher committed Jan 26, 2025
1 parent 2bd5bbb commit 1748e8e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions core/src/main/java/ch/cyberduck/core/AbstractProtocol.java
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,10 @@ public String getDefaultHostname() {

@Override
public Set<Location.Name> getRegions() {
final String region = this.getRegion();
if(StringUtils.isNotBlank(region)) {
return this.toLocations(Collections.singletonList(region));
}
return Collections.emptySet();
}

Expand Down
4 changes: 4 additions & 0 deletions core/src/main/java/ch/cyberduck/core/Profile.java
Original file line number Diff line number Diff line change
Expand Up @@ -457,6 +457,10 @@ public String getAuthorization() {
public Set<Location.Name> getRegions() {
final List<String> regions = this.list(REGIONS_KEY);
if(regions.isEmpty()) {
final String region = this.getRegion();
if(StringUtils.isNotBlank(region)) {
return parent.toLocations(Collections.singletonList(region));
}
return parent.getRegions();
}
return parent.toLocations(regions);
Expand Down

0 comments on commit 1748e8e

Please sign in to comment.