respect empty subdomain list

This commit is contained in:
Peter Hormanns 2017-06-29 10:35:02 +02:00
parent 70587f2970
commit c1aca570f7

View File

@ -196,8 +196,11 @@ public class Domain extends AbstractEntity {
StringBuffer aliases = new StringBuffer(); StringBuffer aliases = new StringBuffer();
for (String sub : subs) { for (String sub : subs) {
aliases.append(' '); aliases.append(' ');
aliases.append(sub.trim()); final String trimmed = sub.trim();
aliases.append('.'); if (trimmed != null && !trimmed.isEmpty()) {
aliases.append(trimmed);
aliases.append('.');
}
aliases.append(name); aliases.append(name);
} }
return aliases.toString(); return aliases.toString();