summaryrefslogtreecommitdiff
path: root/app/models/ci/runner.rb
diff options
context:
space:
mode:
authorDouwe Maan <douwe@selenight.nl>2017-02-22 16:50:15 -0600
committerDouwe Maan <douwe@selenight.nl>2017-02-23 09:33:05 -0600
commit1fe7501b49f896b74102c4b970310aa9ae34da85 (patch)
treece271afb0fbaaa14291c1dc9009cd7815ee25463 /app/models/ci/runner.rb
parentbdbc7d967a0c3d95d5e4ea19a2a5be41268d3540 (diff)
downloadgitlab-ce-1fe7501b49f896b74102c4b970310aa9ae34da85.tar.gz
Revert "Prefer leading style for Style/DotPosition"
This reverts commit cb10b725c8929b8b4460f89c9d96c773af39ba6b.
Diffstat (limited to 'app/models/ci/runner.rb')
-rw-r--r--app/models/ci/runner.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/app/models/ci/runner.rb b/app/models/ci/runner.rb
index 9cf6164e8dd..a120112e882 100644
--- a/app/models/ci/runner.rb
+++ b/app/models/ci/runner.rb
@@ -23,15 +23,15 @@ module Ci
scope :ordered, ->() { order(id: :desc) }
scope :owned_or_shared, ->(project_id) do
- joins('LEFT JOIN ci_runner_projects ON ci_runner_projects.runner_id = ci_runners.id')
- .where("ci_runner_projects.gl_project_id = :project_id OR ci_runners.is_shared = true", project_id: project_id)
+ joins('LEFT JOIN ci_runner_projects ON ci_runner_projects.runner_id = ci_runners.id').
+ where("ci_runner_projects.gl_project_id = :project_id OR ci_runners.is_shared = true", project_id: project_id)
end
scope :assignable_for, ->(project) do
# FIXME: That `to_sql` is needed to workaround a weird Rails bug.
# Without that, placeholders would miss one and couldn't match.
- where(locked: false)
- .where.not("id IN (#{project.runners.select(:id).to_sql})").specific
+ where(locked: false).
+ where.not("id IN (#{project.runners.select(:id).to_sql})").specific
end
validate :tag_constraints