Fixup location conflict message for bare domain
This commit is contained in:
@@ -554,7 +554,7 @@ function getDuplicateErrorDetails(errorMessage, locations, portBindings) {
|
||||
if (match[2] === 'locations.subdomain') {
|
||||
for (let i = 0; i < locations.length; i++) {
|
||||
const { subdomain, domain, type } = locations[i];
|
||||
if (match[1] !== `${subdomain}-${domain}`) continue;
|
||||
if (match[1] !== (subdomain ? `${subdomain}-${domain}` : domain)) continue;
|
||||
|
||||
return new BoxError(BoxError.ALREADY_EXISTS, `${type} location '${dns.fqdn(subdomain, domain)}' is in use`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user