AC-607 Fixed parsing of extra_vars on job_template. '' was not being recognized as !== stringified JSON.

This commit is contained in:
Chris Houseknecht 2013-11-05 19:09:44 +00:00
parent 337eaf2d1b
commit d17b683c35

View File

@ -315,7 +315,8 @@ function JobsEdit ($scope, $rootScope, $compile, $location, $log, $routeParams,
if (fld == 'variables') {
// Parse extra_vars, converting to YAML.
if ($.isEmptyObject(data.extra_vars) || data.extra_vars == "\{\}" || data.extra_vars == "null") {
if ($.isEmptyObject(data.extra_vars) || data.extra_vars == "\{\}" || data.extra_vars == "null"
|| data.extra_vars == "" || data.extra_vars == null) {
scope.variables = "---";
}
else {