mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-31 20:02:09 +00:00
add pronoun field to user profiles
This commit is contained in:
parent
efd0f0f224
commit
f8e48e066a
11 changed files with 19 additions and 1 deletions
|
@ -22,6 +22,7 @@ type UpdateOptions struct {
|
|||
Website optional.Option[string]
|
||||
Location optional.Option[string]
|
||||
Description optional.Option[string]
|
||||
Pronouns optional.Option[string]
|
||||
AllowGitHook optional.Option[bool]
|
||||
AllowImportLocal optional.Option[bool]
|
||||
MaxRepoCreation optional.Option[int]
|
||||
|
@ -54,6 +55,11 @@ func UpdateUser(ctx context.Context, u *user_model.User, opts *UpdateOptions) er
|
|||
|
||||
cols = append(cols, "full_name")
|
||||
}
|
||||
if opts.Pronouns.Has() {
|
||||
u.Pronouns = opts.Pronouns.Value()
|
||||
|
||||
cols = append(cols, "pronouns")
|
||||
}
|
||||
if opts.Website.Has() {
|
||||
u.Website = opts.Website.Value()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue