Skip to content

Commit 0b95d94

Browse files
garymoonGiteaBot
authored andcommitted
Respect the REGISTER_MANUAL_CONFIRM setting when registering via OIDC (go-gitea#24035)
This change prevents Gitea from bypassing the manual approval process for newly registered users when OIDC is used. - Resolves go-gitea#23392 Signed-off-by: Gary Moon <[email protected]>
1 parent b1094ff commit 0b95d94

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

routers/web/auth/oauth.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -963,7 +963,7 @@ func SignInOAuthCallback(ctx *context.Context) {
963963
}
964964

965965
overwriteDefault := &user_model.CreateUserOverwriteOptions{
966-
IsActive: util.OptionalBoolOf(!setting.OAuth2Client.RegisterEmailConfirm),
966+
IsActive: util.OptionalBoolOf(!setting.OAuth2Client.RegisterEmailConfirm && !setting.Service.RegisterManualConfirm),
967967
}
968968

969969
source := authSource.Cfg.(*oauth2.Source)

0 commit comments

Comments
 (0)