summaryrefslogtreecommitdiff
path: root/app/finders
diff options
context:
space:
mode:
authorYorick Peterse <yorickpeterse@gmail.com>2016-03-12 15:44:48 +0100
committerYorick Peterse <yorickpeterse@gmail.com>2016-03-12 15:44:48 +0100
commit3b76b73ab178f0504e2a9be934fb13f239c81857 (patch)
tree048256514ade7fd80bc05ee7d091aad1e05cc534 /app/finders
parent34e8c562363a130ca9f2a6be7959efbc54e64663 (diff)
downloadgitlab-ce-3b76b73ab178f0504e2a9be934fb13f239c81857.tar.gz
Removed User#project_relationsprojects-finder-ee-compatible
GitLab EE adds an extra relation that selects a "project_id" column instead of an "id" column, making it very hard for this method to be re-used in EE. Since using User#authorized_groups in ProjectsFinder#all_groups apparently has no performance impact we can just use it and keep everything compatible with EE.
Diffstat (limited to 'app/finders')
-rw-r--r--app/finders/projects_finder.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/finders/projects_finder.rb b/app/finders/projects_finder.rb
index 2b8fba77bb1..0e5a8f5ee0f 100644
--- a/app/finders/projects_finder.rb
+++ b/app/finders/projects_finder.rb
@@ -53,7 +53,7 @@ class ProjectsFinder
def all_projects(current_user)
if current_user
[
- *current_user.project_relations,
+ current_user.authorized_projects,
public_and_internal_projects
]
else