0
0
mirror of https://github.com/go-gitea/gitea.git synced 2025-11-03 10:55:26 +01:00
This commit is contained in:
Lyle Keeton 2025-10-17 01:15:57 -05:00
parent 970865df06
commit c026cf0bd5

View File

@ -208,8 +208,7 @@ func SignInOAuthCallback(ctx *context.Context) {
} }
} else if setting.OAuth2Client.AccountLinking == setting.OAuth2AccountLinkingAuto { } else if setting.OAuth2Client.AccountLinking == setting.OAuth2AccountLinkingAuto {
// allow ACCOUNT_LINKING=auto to work without ENABLE_AUTO_REGISTRATION. // allow ACCOUNT_LINKING=auto to work without ENABLE_AUTO_REGISTRATION.
var user *user_model.User user := &user_model.User{Email: gothUser.Email}
user = &user_model.User{Email: gothUser.Email}
hasUser, err := user_model.GetUser(ctx, user) hasUser, err := user_model.GetUser(ctx, user)
if err != nil { if err != nil {
ctx.ServerError("UserLinkAccount", err) ctx.ServerError("UserLinkAccount", err)