Skip to content
Snippets Groups Projects
Verified Commit bdda1eed authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

Fix 404 on group page if user is not member of page

parent 774af930
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -12,11 +12,11 @@
= link_to projects_group_path(@group), title: 'Projects' do
Projects
%li.divider
- if @group && can?(current_user, :admin_group, @group)
- if can?(current_user, :admin_group, @group)
%li
= link_to edit_group_path(@group) do
Edit Group
- if access = @group.users.find(current_user.id)
- if access = @group.users.find_by(id: current_user.id)
%li
= link_to leave_group_group_members_path(@group),
data: { confirm: leave_group_message(@group.name) }, method: :delete, title: 'Leave group' do
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment