diff options
author | Stan Hu <stanhu@gmail.com> | 2016-05-24 17:55:57 -0700 |
---|---|---|
committer | Stan Hu <stanhu@gmail.com> | 2016-05-24 18:14:12 -0700 |
commit | b359d5d57f4b836c04e9e2ef7e1fcb3775bd5305 (patch) | |
tree | b42616e6cfb255ba085c60c7e8e26fe014f4ddd9 /app/finders | |
parent | d6e5299fb696ff4aae8bb78b28542f2c87a53dba (diff) | |
download | gitlab-ce-b359d5d57f4b836c04e9e2ef7e1fcb3775bd5305.tar.gz |
Fix groups API to list only user's accessible projects
Closes #17496
Diffstat (limited to 'app/finders')
-rw-r--r-- | app/finders/group_projects_finder.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/finders/group_projects_finder.rb b/app/finders/group_projects_finder.rb index 3b9a421b118..aa8f4c1d0e4 100644 --- a/app/finders/group_projects_finder.rb +++ b/app/finders/group_projects_finder.rb @@ -18,7 +18,7 @@ class GroupProjectsFinder < UnionFinder projects = [] if current_user - if @group.users.include?(current_user) + if @group.users.include?(current_user) || current_user.admin? projects << @group.projects unless only_shared projects << @group.shared_projects unless only_owned else |