chore: minor (#19767)

This commit is contained in:
Thomas Becker 2025-03-14 11:32:25 +01:00 • committed by GitHub
parent 5ef4b50e1f
commit ee9720c9b0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -5,7 +5,6 @@ import (
"net/http"
"net/url"
"strings"
"time"
"github.com/evcc-io/evcc/util"
"github.com/evcc-io/evcc/util/oauth"
@ -121,8 +120,6 @@ func (v *Identity) fetchTokenCredentials(code string) error {
return fmt.Errorf("failed to fetch token credentials: %w", err)
}
res.Expiry = time.Now().Add(time.Duration(res.ExpiresIn) * time.Second)
// Parse ID token without verification to extract UUID
parser := jwt.NewParser(jwt.WithoutClaimsValidation())
token, _, err := parser.ParseUnverified(res.IDToken, jwt.MapClaims{})