summaryrefslogtreecommitdiff
path: root/app/assets/javascripts
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzegorz@gitlab.com>2018-12-21 12:19:23 +0000
committerGrzegorz Bizon <grzegorz@gitlab.com>2018-12-21 12:19:23 +0000
commit6749ef30b3484625de573ecf1709d34b4176421d (patch)
tree723cd57836c6d59a3ca28be189cb6567e6cec1d8 /app/assets/javascripts
parent7f334fdfafd5ea8a1c4277dcf4b1cb56e79c529b (diff)
parentc111e2657df22c811191135369d599923dc89f54 (diff)
downloadgitlab-ce-6749ef30b3484625de573ecf1709d34b4176421d.tar.gz
Merge branch 'feature/option-to-make-variables-protected' into 'master'
Option to make variables protected by default Closes #51822 See merge request gitlab-org/gitlab-ce!22744
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r--app/assets/javascripts/ci_variable_list/ci_variable_list.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/assets/javascripts/ci_variable_list/ci_variable_list.js b/app/assets/javascripts/ci_variable_list/ci_variable_list.js
index ee0f7cda189..5b20fa141cd 100644
--- a/app/assets/javascripts/ci_variable_list/ci_variable_list.js
+++ b/app/assets/javascripts/ci_variable_list/ci_variable_list.js
@@ -36,7 +36,9 @@ export default class VariableList {
},
protected: {
selector: '.js-ci-variable-input-protected',
- default: 'false',
+ // use `attr` instead of `data` as we don't want the value to be
+ // converted. we need the value as a string.
+ default: $('.js-ci-variable-input-protected').attr('data-default'),
},
environment_scope: {
// We can't use a `.js-` class here because