diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-09 12:14:13 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-09-09 12:14:13 +0300 |
commit | 6021fa2fc624b7d6902273bae55c5b8b2b2b3fff (patch) | |
tree | 54d044a94c33f737d46ecb4829930868fd79105e /app/finders | |
parent | 377c02f959f45d07a6d1f3c4d7f5afc6ad5162ff (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/finders')
-rw-r--r-- | app/finders/incident_management/timeline_events_finder.rb | 2 | ||||
-rw-r--r-- | app/finders/issuable_finder.rb | 26 | ||||
-rw-r--r-- | app/finders/merge_requests/by_approvals_finder.rb | 4 | ||||
-rw-r--r-- | app/finders/user_groups_counter.rb | 6 |
4 files changed, 18 insertions, 20 deletions
diff --git a/app/finders/incident_management/timeline_events_finder.rb b/app/finders/incident_management/timeline_events_finder.rb index 09de46bb79f..aaf3133236a 100644 --- a/app/finders/incident_management/timeline_events_finder.rb +++ b/app/finders/incident_management/timeline_events_finder.rb @@ -31,7 +31,7 @@ module IncidentManagement end def sort(collection) - collection.order_occurred_at_asc + collection.order_occurred_at_asc_id_asc end end end diff --git a/app/finders/issuable_finder.rb b/app/finders/issuable_finder.rb index 47b2a460e6f..9f331d381aa 100644 --- a/app/finders/issuable_finder.rb +++ b/app/finders/issuable_finder.rb @@ -58,19 +58,19 @@ class IssuableFinder class << self def scalar_params @scalar_params ||= %i[ - assignee_id - assignee_username - author_id - author_username - crm_contact_id - crm_organization_id - label_name - milestone_title - release_tag - my_reaction_emoji - search - in - ] + assignee_id + assignee_username + author_id + author_username + crm_contact_id + crm_organization_id + label_name + milestone_title + release_tag + my_reaction_emoji + search + in + ] end def array_params diff --git a/app/finders/merge_requests/by_approvals_finder.rb b/app/finders/merge_requests/by_approvals_finder.rb index 94f13468327..8b2e9aa8df1 100644 --- a/app/finders/merge_requests/by_approvals_finder.rb +++ b/app/finders/merge_requests/by_approvals_finder.rb @@ -71,9 +71,7 @@ module MergeRequests # # @param [ActiveRecord::Relation] items the activerecord relation def with_any_approvals(items) - items.select_from_union([ - items.with_approvals - ]) + items.select_from_union([items.with_approvals]) end # Merge requests approved by given usernames diff --git a/app/finders/user_groups_counter.rb b/app/finders/user_groups_counter.rb index 7dbc8502be2..e8e552510cd 100644 --- a/app/finders/user_groups_counter.rb +++ b/app/finders/user_groups_counter.rb @@ -8,9 +8,9 @@ class UserGroupsCounter def execute Namespace.unscoped do Namespace.from_union([ - groups, - project_groups - ]).group(:user_id).count # rubocop: disable CodeReuse/ActiveRecord + groups, + project_groups + ]).group(:user_id).count # rubocop: disable CodeReuse/ActiveRecord end end |