Correctly format incoming environment names
This commit is contained in:
parent
2daad4d057
commit
5210b9e17a
@ -18,14 +18,16 @@ export default {
|
|||||||
|
|
||||||
data: function () {
|
data: function () {
|
||||||
const {
|
const {
|
||||||
name,
|
environment_names,
|
||||||
description,
|
|
||||||
environments = [ createEnvironment() ]
|
|
||||||
} = this.initialData
|
} = this.initialData
|
||||||
|
|
||||||
|
const environments = (
|
||||||
|
environment_names.length > 0
|
||||||
|
? environment_names
|
||||||
|
: [""]
|
||||||
|
).map(createEnvironment)
|
||||||
|
|
||||||
return {
|
return {
|
||||||
name,
|
|
||||||
description,
|
|
||||||
environments,
|
environments,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user