BigW Consortium Gitlab
GroupProjectsFinder#collection_with_user would run the following code: if group.users.include?(current_user) When running this code for multiple groups this would result in one query being executed for every group. This commit simple removes the entire "if" statement with the code of the "else" statement. This ensures both paths use the same code, and removes the need for explicitly checking if a user is a member of the group.
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
admin | Loading commit data... | |
concerns | Loading commit data... | |
README.md | Loading commit data... | |
access_requests_finder.rb | Loading commit data... | |
autocomplete_users_finder.rb | Loading commit data... | |
branches_finder.rb | Loading commit data... | |
clusters_finder.rb | Loading commit data... | |
contributed_projects_finder.rb | Loading commit data... | |
environments_finder.rb | Loading commit data... | |
events_finder.rb | Loading commit data... | |
fork_projects_finder.rb | Loading commit data... | |
group_descendants_finder.rb | Loading commit data... | |
group_finder.rb | Loading commit data... | |
group_members_finder.rb | Loading commit data... | |
group_projects_finder.rb | Loading commit data... | |
groups_finder.rb | Loading commit data... | |
issuable_finder.rb | Loading commit data... | |
issues_finder.rb | Loading commit data... | |
joined_groups_finder.rb | Loading commit data... | |
labels_finder.rb | Loading commit data... | |
members_finder.rb | Loading commit data... | |
merge_request_target_project_finder.rb | Loading commit data... | |
merge_requests_finder.rb | Loading commit data... | |
milestones_finder.rb | Loading commit data... | |
move_to_project_finder.rb | Loading commit data... | |
notes_finder.rb | Loading commit data... | |
personal_access_tokens_finder.rb | Loading commit data... | |
personal_projects_finder.rb | Loading commit data... | |
pipeline_schedules_finder.rb | Loading commit data... | |
pipelines_finder.rb | Loading commit data... | |
projects_finder.rb | Loading commit data... | |
runner_jobs_finder.rb | Loading commit data... | |
snippets_finder.rb | Loading commit data... | |
tags_finder.rb | Loading commit data... | |
todos_finder.rb | Loading commit data... | |
union_finder.rb | Loading commit data... | |
user_recent_events_finder.rb | Loading commit data... | |
users_finder.rb | Loading commit data... |