Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib/ci
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-04-16 21:52:01 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-04-18 14:17:48 +0300
commitcf3e3effb01215c2556ba509d3cb4debe1d901e8 (patch)
treec8d56d2aacf2c0e0818fbc7a94ea7e89c45c8d6e /lib/ci
parenta6260b1eb7b4f30817d0cc5dbd80c860b5ed8a31 (diff)
Minor refactoring in code related to job variables
Diffstat (limited to 'lib/ci')
-rw-r--r--lib/ci/gitlab_ci_yaml_processor.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/ci/gitlab_ci_yaml_processor.rb b/lib/ci/gitlab_ci_yaml_processor.rb
index e152de590de..209da7ad81f 100644
--- a/lib/ci/gitlab_ci_yaml_processor.rb
+++ b/lib/ci/gitlab_ci_yaml_processor.rb
@@ -45,11 +45,7 @@ module Ci
end
def job_variables(name)
- if job = @jobs[name.to_sym]
- job[:variables] || []
- else
- []
- end
+ @jobs[name.to_sym].try(:fetch, :variables, []) || []
end
private