diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-03 12:08:20 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-03 12:08:20 +0300 |
commit | a1aeaba23e388ac96d34c135c6c55e414f823487 (patch) | |
tree | 12ac28cdba58353efe18053028d6028a965c6358 /lib/expand_variables.rb | |
parent | d72fedf168dafcb38bd51b67f86804738000fb48 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/expand_variables.rb')
-rw-r--r-- | lib/expand_variables.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/expand_variables.rb b/lib/expand_variables.rb index 45af30f46dc..3a50925d628 100644 --- a/lib/expand_variables.rb +++ b/lib/expand_variables.rb @@ -7,7 +7,7 @@ module ExpandVariables value.gsub(/\$([a-zA-Z_][a-zA-Z0-9_]*)|\${\g<1>}|%\g<1>%/) do variables_hash ||= transform_variables(variables) - variables_hash[$1 || $2] + variables_hash[Regexp.last_match(1) || Regexp.last_match(2)] end end |