Auth: Org Invite and Team API SignedInUser interfacing (#73085)
* fix ngalert Evaluate sig change * interface for teams and org invites * Update pkg/api/org_invite.go Co-authored-by: Ieva <ieva.vasiljeva@grafana.com> --------- Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
This commit is contained in:
@@ -155,7 +155,7 @@ func (ctx *ReqContext) writeErrOrFallback(status int, message string, err error)
|
||||
}
|
||||
|
||||
func (ctx *ReqContext) HasUserRole(role org.RoleType) bool {
|
||||
return ctx.OrgRole.Includes(role)
|
||||
return ctx.SignedInUser.GetOrgRole().Includes(role)
|
||||
}
|
||||
|
||||
func (ctx *ReqContext) HasHelpFlag(flag user.HelpFlags1) bool {
|
||||
|
||||
Reference in New Issue
Block a user