GetRolesForUser gets the roles that a user has.
(name string, domain ...string)
| 16 | |
| 17 | // GetRolesForUser gets the roles that a user has. |
| 18 | func (e *SyncedEnforcer) GetRolesForUser(name string, domain ...string) ([]string, error) { |
| 19 | e.m.RLock() |
| 20 | defer e.m.RUnlock() |
| 21 | return e.Enforcer.GetRolesForUser(name, domain...) |
| 22 | } |
| 23 | |
| 24 | // GetUsersForRole gets the users that has a role. |
| 25 | func (e *SyncedEnforcer) GetUsersForRole(name string, domain ...string) ([]string, error) { |
nothing calls this directly
no test coverage detected