Skip to content

isUserMemberOf(), getGroupMembershipForUser() and getUsersForGroup() seem not working? #237

@martin0258

Description

@martin0258

Actual result

I have 1 user belonging to 1 group. However, when calling isUserMemberOf with the user and the group, it returned false. When calling getGroupMembershipForUser with the user, it returned empty (i.e., no groups membership). When calling getUsersForGroup with the group, it also returned empty (i.e., no users).

Expected result

  1. isUserMemberOf should return true.
  2. getGroupMembershipForUser should return the group.
  3. getUsersForGroup should return the user.

Discussion

I'm not sure if it is a bug. I found someone indicated that the "member" attribute does not include members for primary group membership, and we should use primaryGroupToken and primaryGroupId to check the membership.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions