Skip to content

Commit c6a89b4

Browse files
author
Earl Warren
committed
Merge pull request '[gitea] cherry-pick' (go-gitea#2324) from earl-warren/forgejo:wip-gitea-cherry-pick into forgejo
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/2324 Reviewed-by: Gusted <[email protected]>
2 parents 98e7753 + 9c4e0c2 commit c6a89b4

File tree

4 files changed

+159
-11
lines changed

4 files changed

+159
-11
lines changed

models/user/user.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -436,14 +436,14 @@ func (u *User) GetDisplayName() string {
436436
}
437437

438438
// GetCompleteName returns the the full name and username in the form of
439-
// "Full Name (@username)" if full name is not empty, otherwise it returns
440-
// "@username".
439+
// "Full Name (username)" if full name is not empty, otherwise it returns
440+
// "username".
441441
func (u *User) GetCompleteName() string {
442442
trimmedFullName := strings.TrimSpace(u.FullName)
443443
if len(trimmedFullName) > 0 {
444-
return fmt.Sprintf("%s (@%s)", trimmedFullName, u.Name)
444+
return fmt.Sprintf("%s (%s)", trimmedFullName, u.Name)
445445
}
446-
return fmt.Sprintf("@%s", u.Name)
446+
return u.Name
447447
}
448448

449449
func gitSafeName(name string) string {

0 commit comments

Comments
 (0)