'My sites' menu does not show any site when the user belongs to an organization without pages, and to several sites, where the query to retrieve the groups returns the organization's group as the first one, removing it from the list.
As the hasPermission asks only for one element (see MySitesPanelCategory.java:75), then siteGroups variable is empty, because the getMySiteGroups method removed it.
Steps to reproduce:
- create an organization, without pages on its site.
- create several groups, with pages. The names of the groups should be such that returning the groups of a user, the retrieved one first must be the organization group.
- Browse the portal, opening product menu
Expected behaviour: Site menu displays the sites the user belongs to.
Actual behaviour: Site menu displays no sites, although the user belongs to groups with pages.