filter out ""

This commit is contained in:
Sebastian Stenzel
2026-03-12 09:21:55 +01:00
parent c3c7a23ccd
commit e066f155b2

View File

@@ -154,7 +154,10 @@ public class Environment {
public Set<String> hubAllowedHosts() {
var allowedHubHostsString = System.getProperty(HUB_ALLOWED_HOSTS_PROP_NAME, "");
return Arrays.stream(allowedHubHostsString.split(",")).map(String::trim).collect(Collectors.toUnmodifiableSet());
return Arrays.stream(allowedHubHostsString.split(","))
.map(String::trim)
.filter(Predicate.not(String::isEmpty))
.collect(Collectors.toUnmodifiableSet());
}
public boolean hubTrustOnFirstUse() {