diff options
author | Matija Čupić <matteeyah@gmail.com> | 2018-03-17 14:17:40 +0300 |
---|---|---|
committer | Matija Čupić <matteeyah@gmail.com> | 2018-03-17 18:33:36 +0300 |
commit | 53915c5c54c06182717b457375ae771ee01558fd (patch) | |
tree | e270fe3c239f6fd91871b5157665abfe2aa8867b /app/models/ci/variable.rb | |
parent | 763c82f0b304362be71ca82e551381609db19bf8 (diff) |
Alias secret_key and secret_value to key and value
Diffstat (limited to 'app/models/ci/variable.rb')
-rw-r--r-- | app/models/ci/variable.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/ci/variable.rb b/app/models/ci/variable.rb index 7c71291de84..bcad55f115f 100644 --- a/app/models/ci/variable.rb +++ b/app/models/ci/variable.rb @@ -6,6 +6,9 @@ module Ci belongs_to :project + alias_attribute :secret_key, :key + alias_attribute :secret_value, :value + validates :key, uniqueness: { scope: [:project_id, :environment_scope], message: "(%{value}) has already been taken" |