From b854930a96b2927ae810353f486d27c69c76b5d7 Mon Sep 17 00:00:00 2001 From: Giteabot Date: Wed, 15 Oct 2025 15:30:46 +0800 Subject: [PATCH] Fix a bug missed return (#35655) (#35671) Backport #35655 by @lunny Co-authored-by: Lunny Xiao --- routers/web/auth/oauth2_provider.go | 1 + 1 file changed, 1 insertion(+) diff --git a/routers/web/auth/oauth2_provider.go b/routers/web/auth/oauth2_provider.go index 1804b5b193..3b07e367f3 100644 --- a/routers/web/auth/oauth2_provider.go +++ b/routers/web/auth/oauth2_provider.go @@ -639,6 +639,7 @@ func handleAuthorizationCode(ctx *context.Context, form forms.AccessTokenForm, s ErrorCode: oauth2_provider.AccessTokenErrorCodeInvalidRequest, ErrorDescription: "cannot proceed your request", }) + return } resp, tokenErr := oauth2_provider.NewAccessTokenResponse(ctx, authorizationCode.Grant, serverKey, clientKey) if tokenErr != nil {