When validating that envs have names, make sure that names containing only strings are not valid

This commit is contained in:
leigh-mil 2019-11-04 13:57:52 -05:00
parent 637a366baf
commit 045e06abee

View File

@ -91,7 +91,9 @@ export default {
if (this.environments.length > 1) {
// only want to display this error if we have multiple envs and one or
// more do not have names
return this.environments.every(e => e.name !== '')
return this.environments.every(
e => !e.name.match(/^\s+$/) && e.name !== ''
)
} else {
return true
}