fix: multi role with oauth (#61)
This commit is contained in:
@@ -54,7 +54,7 @@ func Token(ctx context.Context, roles []string) (*model.AuthResponse, error) {
|
||||
|
||||
if len(roles) > 0 {
|
||||
for _, v := range roles {
|
||||
if !utils.StringContains(claimRoles, v) {
|
||||
if !utils.StringSliceContains(claimRoles, v) {
|
||||
return res, fmt.Errorf(`unauthorized`)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user