]> source.dussan.org Git - gitea.git/commit
Return an empty string when a repo has no avatar in the repo API (#31187)
authorKemal Zebari <60799661+kemzeb@users.noreply.github.com>
Sat, 1 Jun 2024 11:49:42 +0000 (04:49 -0700)
committerGitHub <noreply@github.com>
Sat, 1 Jun 2024 11:49:42 +0000 (11:49 +0000)
commitab458ce10be59669c810ba43af41f2ba2e72ea5b
tree0f20e006e4220e27f0c3c869c5f32a54a46c459a
parenta4275951ba9635e9b7de6a91812b6cc9622c8c9b
Return an empty string when a repo has no avatar in the repo API (#31187)

Resolves #31167.

https://github.com/go-gitea/gitea/pull/30885 changed the behavior of
`repo.AvatarLink()` where it can now take the empty string and append it
to the app data URL. This does not point to a valid avatar image URL,
and, as the issue mentions, previous Gitea versions returned the empty
string.

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
models/repo/avatar.go