role added to configuration

This commit is contained in:
2023-11-06 22:25:00 +01:00
parent f6120640d2
commit fb24320552
3 changed files with 4 additions and 9 deletions

View File

@ -3,7 +3,6 @@ package provider
import (
"context"
"errors"
"fmt"
"github.com/coreos/go-oidc"
"golang.org/x/oauth2"
@ -99,9 +98,6 @@ func (o *OIDC) GetUser(token string) (User, Roles, error) {
return user, roles, err
}
o.log.WithField("idToken", idToken).Debug("getUser")
// Extract custom claims
if err := idToken.Claims(&user); err != nil {
return user, roles, err
@ -112,10 +108,6 @@ func (o *OIDC) GetUser(token string) (User, Roles, error) {
return user, roles, err
}
o.log.WithField("roles", roles).Debug("getUser")
for i, r := range roles.Roles {
o.log.Debug(fmt.Sprintf("%d, %s", i, r))
}
return user, roles, nil
}