code: def get_users_by_roles(roles=None):
      
      if not isinstance(roles, (tuple, list)):
          roles = [roles]
      mtool = get_tool("portal_membership")
      return mtool.searchForMembers(roles=roles)
docs: Search Plone users by their roles
  
      :param roles: Plone role name or list of roles
      :type roles:  list/str
      :returns: List of Plone users having the role(s)