summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2023-01-04 16:19:56 +0800
committerGitHub <noreply@github.com>2023-01-04 16:19:56 +0800
commitfdbb0b4762d8eb77a82484eb9ac1ef8aacd3f58b (patch)
tree40e79bba842e08f632c533a6f2754c85e48d093e /models
parent32e863439cc6a12c753675a73b603f878c8e3ff0 (diff)
downloadgitea-fdbb0b4762d8eb77a82484eb9ac1ef8aacd3f58b.tar.gz
gitea-fdbb0b4762d8eb77a82484eb9ac1ef8aacd3f58b.zip
fix gravatar disable bug (#22336)
Diffstat (limited to 'models')
-rw-r--r--models/system/setting.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/system/setting.go b/models/system/setting.go
index 8e16547d92..3eb8b3955d 100644
--- a/models/system/setting.go
+++ b/models/system/setting.go
@@ -275,7 +275,7 @@ func Init() error {
}
}
- if enableFederatedAvatarSetting.GetValueBool() {
+ if GravatarSourceURL != nil && enableFederatedAvatarSetting.GetValueBool() {
LibravatarService = libravatar.New()
if GravatarSourceURL.Scheme == "https" {
LibravatarService.SetUseHTTPS(true)