diff options
author | Douwe Maan <douwe@selenight.nl> | 2017-02-22 10:55:08 -0600 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2017-02-23 09:32:22 -0600 |
commit | 206953a430e442fbbd06984b1120890dbf8d3f79 (patch) | |
tree | 74922128d6a26bc0c9024b8588c9f38a6250cc0d /app/finders | |
parent | f72a65603db4dfdb41f327ab03892eed5dadb57e (diff) | |
download | gitlab-ce-206953a430e442fbbd06984b1120890dbf8d3f79.tar.gz |
Prefer leading style for Style/DotPosition
Diffstat (limited to 'app/finders')
-rw-r--r-- | app/finders/environments_finder.rb | 10 | ||||
-rw-r--r-- | app/finders/group_members_finder.rb | 6 |
2 files changed, 8 insertions, 8 deletions
diff --git a/app/finders/environments_finder.rb b/app/finders/environments_finder.rb index 52c73abc31d..a59f8c1efa3 100644 --- a/app/finders/environments_finder.rb +++ b/app/finders/environments_finder.rb @@ -17,12 +17,12 @@ class EnvironmentsFinder deployments.none end - environment_ids = deployments. - group(:environment_id). - select(:environment_id) + environment_ids = deployments + .group(:environment_id) + .select(:environment_id) - environments = project.environments.available. - where(id: environment_ids).order_by_last_deployed_at.to_a + environments = project.environments.available + .where(id: environment_ids).order_by_last_deployed_at.to_a environments.select! do |environment| Ability.allowed?(current_user, :read_environment, environment) diff --git a/app/finders/group_members_finder.rb b/app/finders/group_members_finder.rb index 9f2206346ce..873a253e2b5 100644 --- a/app/finders/group_members_finder.rb +++ b/app/finders/group_members_finder.rb @@ -8,9 +8,9 @@ class GroupMembersFinder < Projects::ApplicationController return group_members unless @group.parent - parents_members = GroupMember.non_request. - where(source_id: @group.ancestors.select(:id)). - where.not(user_id: @group.users.select(:id)) + parents_members = GroupMember.non_request + .where(source_id: @group.ancestors.select(:id)) + .where.not(user_id: @group.users.select(:id)) wheres = ["members.id IN (#{group_members.select(:id).to_sql})"] wheres << "members.id IN (#{parents_members.select(:id).to_sql})" |