diff --git a/README.md b/README.md index 2eebd78c..83333cad 100644 --- a/README.md +++ b/README.md @@ -39,7 +39,7 @@ oauth2Config := oauth2.Config{ Endpoint: provider.Endpoint(), // "openid" is a required scope for OpenID Connect flows. - Scopes: []string{oidc.ScopeOpenID, "profile", "email"}, + Scopes: []string{oidc.ScopeOpenID, oidc.ScopeProfile, oidc.ScopeEmail}, } ``` diff --git a/example/idtoken/app.go b/example/idtoken/app.go index 80b0709e..298466b3 100644 --- a/example/idtoken/app.go +++ b/example/idtoken/app.go @@ -59,7 +59,7 @@ func main() { ClientSecret: clientSecret, Endpoint: provider.Endpoint(), RedirectURL: "http://127.0.0.1:5556/auth/google/callback", - Scopes: []string{oidc.ScopeOpenID, "profile", "email"}, + Scopes: []string{oidc.ScopeOpenID, oidc.ScopeProfile, oidc.ScopeEmail}, } http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { diff --git a/example/userinfo/app.go b/example/userinfo/app.go index c530cffb..38ed3731 100644 --- a/example/userinfo/app.go +++ b/example/userinfo/app.go @@ -54,7 +54,7 @@ func main() { ClientSecret: clientSecret, Endpoint: provider.Endpoint(), RedirectURL: "http://127.0.0.1:5556/auth/google/callback", - Scopes: []string{oidc.ScopeOpenID, "profile", "email"}, + Scopes: []string{oidc.ScopeOpenID, oidc.ScopeProfile, oidc.ScopeEmail}, } http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {