File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
services/auth/source/oauth2 Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -72,8 +72,6 @@ func SignInOAuth(ctx *context.Context) {
7272
7373// SignInOAuthCallback handles the callback from the given provider
7474func SignInOAuthCallback (ctx * context.Context ) {
75- provider := ctx .PathParam ("provider" )
76-
7775 if ctx .Req .FormValue ("error" ) != "" {
7876 var errorKeyValues []string
7977 for k , vv := range ctx .Req .Form {
@@ -86,7 +84,8 @@ func SignInOAuthCallback(ctx *context.Context) {
8684 }
8785
8886 // first look if the provider is still active
89- authSource , err := auth .GetActiveOAuth2SourceByAuthName (ctx , provider )
87+ authName := ctx .PathParam ("provider" )
88+ authSource , err := auth .GetActiveOAuth2SourceByAuthName (ctx , authName )
9089 if err != nil {
9190 ctx .ServerError ("SignIn" , err )
9291 return
Original file line number Diff line number Diff line change @@ -12,8 +12,10 @@ import (
1212
1313// BaseProvider represents a common base for Provider
1414type BaseProvider struct {
15- name string
16- displayName string
15+ name string
16+ displayName string
17+
18+ // TODO: maybe some providers also support SSH public keys, then they can set this to true
1719 supportSSHPublicKey bool
1820}
1921
You can’t perform that action at this time.
0 commit comments