mirror of
https://github.com/go-gitea/gitea.git
synced 2024-10-29 08:17:31 -04:00
Don't ignore gravatar error
This commit is contained in:
parent
33f3165296
commit
23f0728879
@ -197,8 +197,10 @@ func HashEmail(email string) string {
|
|||||||
// to return full URL if user enables Gravatar-like service.
|
// to return full URL if user enables Gravatar-like service.
|
||||||
func AvatarLink(email string) string {
|
func AvatarLink(email string) string {
|
||||||
if setting.EnableFederatedAvatar && setting.LibravatarService != nil {
|
if setting.EnableFederatedAvatar && setting.LibravatarService != nil {
|
||||||
// TODO: This doesn't check any error. AvatarLink should return (string, error)
|
url, err := setting.LibravatarService.FromEmail(email)
|
||||||
url, _ := setting.LibravatarService.FromEmail(email)
|
if err != nil {
|
||||||
|
log.Error(4, "LibravatarService.FromEmail(email=%s): error %v", email, err)
|
||||||
|
}
|
||||||
return url
|
return url
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user