We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b48df10 commit 26437a0Copy full SHA for 26437a0
services/auth/oauth2.go
@@ -27,6 +27,9 @@ var (
27
28
// CheckOAuthAccessToken returns uid of user from oauth token
29
func CheckOAuthAccessToken(ctx context.Context, accessToken string) int64 {
30
+ if !setting.OAuth2.Enabled {
31
+ return 0
32
+ }
33
// JWT tokens require a "."
34
if !strings.Contains(accessToken, ".") {
35
return 0
0 commit comments