diff options
author | Job van der Voort <jobvandervoort@gmail.com> | 2015-04-21 17:21:51 +0300 |
---|---|---|
committer | Job van der Voort <jobvandervoort@gmail.com> | 2015-04-21 17:21:51 +0300 |
commit | a8e93b7f51d968c1380ed210499869b62b07fd15 (patch) | |
tree | c864e80dfd9cf4f83fcede678acc986e3a125bf5 /app/services/gravatar_service.rb | |
parent | 0625b15a481b3a3edd88110b3c18031ad9068d2f (diff) |
Version 7.10.0.rc5v7.10.0.rc5
Diffstat (limited to 'app/services/gravatar_service.rb')
-rw-r--r-- | app/services/gravatar_service.rb | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/app/services/gravatar_service.rb b/app/services/gravatar_service.rb deleted file mode 100644 index 4bee0c26a68..00000000000 --- a/app/services/gravatar_service.rb +++ /dev/null @@ -1,30 +0,0 @@ -class GravatarService - include Gitlab::CurrentSettings - - def execute(email, size = nil) - if current_application_settings.gravatar_enabled? && email.present? - size = 40 if size.nil? || size <= 0 - - sprintf gravatar_url, - hash: Digest::MD5.hexdigest(email.strip.downcase), - size: size, - email: email.strip - end - end - - def gitlab_config - Gitlab.config.gitlab - end - - def gravatar_config - Gitlab.config.gravatar - end - - def gravatar_url - if gitlab_config.https - gravatar_config.ssl_url - else - gravatar_config.plain_url - end - end -end |