Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

[#55581] only show visible groups within the hover card

Tobias Dillmann3f22bd31c578
diff --git a/app/components/users/hover_card_component.rb b/app/components/users/hover_card_component.rb
index 59ae981b564..afd040da99b 100644
--- a/app/components/users/hover_card_component.rb
+++ b/app/components/users/hover_card_component.rb
@@ -48,7 +48,7 @@ class Users::HoverCardComponent < ApplicationComponent
# "Member of group1, group2 and 3 more"
# The latter string is cut off since the complete list of group names would exceed the allowed `max_length`.
def group_membership_summary(max_length = 40)
- groups = @user.groups
+ groups = @user.groups.visible
return no_group_text if groups.empty?
group_links = linked_group_names(groups)