Skip to content

Commit 4121f95

Browse files
authored
Fix oauth2 error handle not return immediately (#32514)
1 parent 21f7db2 commit 4121f95

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

routers/web/auth/oauth.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,8 @@ func SignInOAuthCallback(ctx *context.Context) {
122122
}
123123
if err, ok := err.(*go_oauth2.RetrieveError); ok {
124124
ctx.Flash.Error("OAuth2 RetrieveError: "+err.Error(), true)
125+
ctx.Redirect(setting.AppSubURL + "/user/login")
126+
return
125127
}
126128
ctx.ServerError("UserSignIn", err)
127129
return

0 commit comments

Comments
 (0)