fix(services): Empty environment variables are not maintained (#836)

pull/845/head
Glowbal 8 years ago committed by Anthony Lapenna
parent 5b81b35bf8
commit 4ff7ee4e60

@ -145,7 +145,7 @@ function ($scope, $state, Service, ServiceHelper, Volume, Network, ImageHelper,
function prepareEnvConfig(config, input) {
var env = [];
input.Env.forEach(function (v) {
if (v.name && v.value) {
if (v.name) {
env.push(v.name + "=" + v.value);
}
});

@ -324,7 +324,7 @@ function ($scope, $stateParams, $state, $location, $anchorScroll, Service, Servi
if (env) {
var variables = [];
env.forEach(function(variable) {
if (variable.key && variable.key !== '' && variable.value && variable.value !== '') {
if (variable.key && variable.key !== '') {
variables.push(variable.key + '=' + variable.value);
}
});

Loading…
Cancel
Save