diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-17 19:05:49 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2023-05-17 19:05:49 +0300 |
commit | 43a25d93ebdabea52f99b05e15b06250cd8f07d7 (patch) | |
tree | dceebdc68925362117480a5d672bcff122fb625b /app/controllers/explore | |
parent | 20c84b99005abd1c82101dfeff264ac50d2df211 (diff) |
Add latest changes from gitlab-org/gitlab@16-0-stable-eev16.0.0-rc42
Diffstat (limited to 'app/controllers/explore')
-rw-r--r-- | app/controllers/explore/groups_controller.rb | 7 | ||||
-rw-r--r-- | app/controllers/explore/projects_controller.rb | 4 |
2 files changed, 8 insertions, 3 deletions
diff --git a/app/controllers/explore/groups_controller.rb b/app/controllers/explore/groups_controller.rb index ac355b861b3..96a7b5b144d 100644 --- a/app/controllers/explore/groups_controller.rb +++ b/app/controllers/explore/groups_controller.rb @@ -7,7 +7,12 @@ class Explore::GroupsController < Explore::ApplicationController urgency :low def index - user = Feature.enabled?(:generic_explore_groups, current_user, type: :experiment) ? nil : current_user + # For gitlab.com, including internal visibility groups here causes + # a major performance issue: https://gitlab.com/gitlab-org/gitlab/-/issues/358944 + # + # For self-hosted users, not including internal groups here causes + # a lack of visibility: https://gitlab.com/gitlab-org/gitlab/-/issues/389041 + user = Gitlab.com? ? nil : current_user render_group_tree GroupsFinder.new(user).execute end diff --git a/app/controllers/explore/projects_controller.rb b/app/controllers/explore/projects_controller.rb index 34745815f3d..eebcbe88ebf 100644 --- a/app/controllers/explore/projects_controller.rb +++ b/app/controllers/explore/projects_controller.rb @@ -88,8 +88,8 @@ class Explore::ProjectsController < Explore::ApplicationController private def load_project_counts - @total_user_projects_count = ProjectsFinder.new(params: { non_public: true }, current_user: current_user).execute - @total_starred_projects_count = ProjectsFinder.new(params: { starred: true }, current_user: current_user).execute + @all_user_projects = ProjectsFinder.new(params: { non_public: true }, current_user: current_user).execute + @all_starred_projects = ProjectsFinder.new(params: { starred: true }, current_user: current_user).execute end def load_projects |