diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-30 09:08:07 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-06-30 09:08:07 +0000 |
commit | d08bee6aaf36fb6cd922f130f5596484c64562c0 (patch) | |
tree | 2476df6e22109ff9fa04db96a8867b2411cf7d5c /lib/sidebars/projects | |
parent | 28fd41cf28bfac77fe877b6cce83594c1f9f21a1 (diff) | |
download | gitlab-ce-d08bee6aaf36fb6cd922f130f5596484c64562c0.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/sidebars/projects')
-rw-r--r-- | lib/sidebars/projects/menus/project_information_menu.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/sidebars/projects/menus/project_information_menu.rb b/lib/sidebars/projects/menus/project_information_menu.rb index eba0389d502..a5f06ebea20 100644 --- a/lib/sidebars/projects/menus/project_information_menu.rb +++ b/lib/sidebars/projects/menus/project_information_menu.rb @@ -51,6 +51,10 @@ module Sidebars end def labels_menu_item + unless can?(context.current_user, :read_label, context.project) + return ::Sidebars::NilMenuItem.new(item_id: :labels) + end + ::Sidebars::MenuItem.new( title: _('Labels'), link: project_labels_path(context.project), @@ -60,6 +64,10 @@ module Sidebars end def members_menu_item + unless can?(context.current_user, :read_project_member, context.project) + return ::Sidebars::NilMenuItem.new(item_id: :members) + end + ::Sidebars::MenuItem.new( title: _('Members'), link: project_project_members_path(context.project), |