loading up the forgejo repo on tangled to test page performance
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Return default avatar url when user id is zero rather than updating database (#34094)

(cherry picked from commit 88352e0b252e9186a5633d39124a8a65ab89f831)

authored by

Lunny Xiao and committed by
Michael Jerger
02d9c7cd 39341df8

+1 -1
+1 -1
models/user/avatar.go
··· 62 62 63 63 // AvatarLinkWithSize returns a link to the user's avatar with size. size <= 0 means default size 64 64 func (u *User) AvatarLinkWithSize(ctx context.Context, size int) string { 65 - if u.IsGhost() { 65 + if u.IsGhost() || u.ID <= 0 { 66 66 return avatars.DefaultAvatarLink() 67 67 } 68 68