mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-08-01 17:38:33 +00:00
Normalize oauth email username (#28561)
This commit is contained in:
parent
657b23d635
commit
54acf7b0d4
8 changed files with 80 additions and 10 deletions
|
@ -55,7 +55,11 @@ func LinkAccount(ctx *context.Context) {
|
|||
}
|
||||
|
||||
gu, _ := gothUser.(goth.User)
|
||||
uname := getUserName(&gu)
|
||||
uname, err := getUserName(&gu)
|
||||
if err != nil {
|
||||
ctx.ServerError("UserSignIn", err)
|
||||
return
|
||||
}
|
||||
email := gu.Email
|
||||
ctx.Data["user_name"] = uname
|
||||
ctx.Data["email"] = email
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue