diff options
author | Igor Drozdov <idrozdov@gitlab.com> | 2019-04-01 17:36:11 +0300 |
---|---|---|
committer | Igor Drozdov <idrozdov@gitlab.com> | 2019-04-01 17:36:11 +0300 |
commit | 04bb35a4b562fd57b14c55645bb1848a50cdef56 (patch) | |
tree | 1bd1ac2af6a5c088ac2529cdbccceeca402d3ebe /lib/api/variables.rb | |
parent | ade207e575ab846f6d354aaccc1382a6e512dd0d (diff) | |
parent | b8118a65d595040bfce2d83d5e38dd63ebfedb58 (diff) | |
download | gitlab-ce-id-split-self-approval-restrictions.tar.gz |
Merge branch 'master' into id-split-self-approval-restrictionsid-split-self-approval-restrictions
Diffstat (limited to 'lib/api/variables.rb')
-rw-r--r-- | lib/api/variables.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/api/variables.rb b/lib/api/variables.rb index d0d81ebc870..3489ba827e4 100644 --- a/lib/api/variables.rb +++ b/lib/api/variables.rb @@ -55,6 +55,10 @@ module API requires :key, type: String, desc: 'The key of the variable' requires :value, type: String, desc: 'The value of the variable' optional :protected, type: String, desc: 'Whether the variable is protected' + + if Gitlab.ee? + optional :environment_scope, type: String, desc: 'The environment_scope of the variable' + end end post ':id/variables' do variable_params = declared_params(include_missing: false) @@ -76,6 +80,10 @@ module API optional :key, type: String, desc: 'The key of the variable' optional :value, type: String, desc: 'The value of the variable' optional :protected, type: String, desc: 'Whether the variable is protected' + + if Gitlab.ee? + optional :environment_scope, type: String, desc: 'The environment_scope of the variable' + end end # rubocop: disable CodeReuse/ActiveRecord put ':id/variables/:key' do |