summaryrefslogtreecommitdiff
path: root/app/models/project.rb
diff options
context:
space:
mode:
authorLin Jen-Shin <godfat@godfat.org>2017-05-27 02:17:46 +0800
committerLin Jen-Shin <godfat@godfat.org>2017-05-27 02:17:46 +0800
commit8f44bc4dc10caf3c9856a8e4bea5ac145a315131 (patch)
treedaa2eaa64604bf134807810a39dbcf50489e5c00 /app/models/project.rb
parent2785bc4faa0eb5c46b0c8b46b77aa4cf1d4ee4b4 (diff)
downloadgitlab-ce-8f44bc4dc10caf3c9856a8e4bea5ac145a315131.tar.gz
Rubocop makes more sense with this
Diffstat (limited to 'app/models/project.rb')
-rw-r--r--app/models/project.rb13
1 files changed, 7 insertions, 6 deletions
diff --git a/app/models/project.rb b/app/models/project.rb
index e85f9020563..fbf2a0a75ca 100644
--- a/app/models/project.rb
+++ b/app/models/project.rb
@@ -1257,12 +1257,13 @@ class Project < ActiveRecord::Base
end
def variables_for(ref)
- vars = if ProtectedBranch.protected?(self, ref) ||
- ProtectedTag.protected?(self, ref)
- variables.to_a
- else
- variables.to_a.reject(&:protected?)
- end
+ vars =
+ if ProtectedBranch.protected?(self, ref) ||
+ ProtectedTag.protected?(self, ref)
+ variables.to_a
+ else
+ variables.to_a.reject(&:protected?)
+ end
vars.map(&:to_runner_variable)
end