From 61965072b330437971e4b317f65321dc94e2f42b Mon Sep 17 00:00:00 2001 From: Kirill Kholodilin Date: Wed, 6 Sep 2023 05:26:34 +0200 Subject: [PATCH] fix(#435): fix scope value for strava (#484) --- providers/strava/strava.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/providers/strava/strava.go b/providers/strava/strava.go index 6402751af..785cc7fb2 100644 --- a/providers/strava/strava.go +++ b/providers/strava/strava.go @@ -10,6 +10,7 @@ import ( "io/ioutil" "net/http" "net/url" + "strings" "github.com/markbates/goth" "golang.org/x/oauth2" @@ -157,9 +158,7 @@ func newConfig(provider *Provider, scopes []string) *oauth2.Config { } if len(scopes) > 0 { - for _, scope := range scopes { - c.Scopes = append(c.Scopes, scope) - } + c.Scopes = []string{strings.Join(scopes, ",")} } else { c.Scopes = []string{"read"} }