summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2018-04-07 07:29:25 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2018-04-07 07:29:25 +0000
commitb21ec884351f41f3321411fed939fb88578d1fef (patch)
treeb159e83eafae1320b2a582fc8ba3d7c72a21ccdc
parente5d1ac83dd97126514323531d16ba237e57a1f17 (diff)
Merged r17263 into 3.4-stable (#28208).
git-svn-id: http://svn.redmine.org/redmine/branches/3.4-stable@17264 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r--app/helpers/application_helper.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index fd8da95d9..792af987c 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -1423,11 +1423,13 @@ module ApplicationHelper
end
if email.present?
gravatar(email.to_s.downcase, options) rescue nil
- else
+ elsif user.is_a?(AnonymousUser)
options[:size] &&= options[:size].to_s
image_tag 'anonymous.png',
GravatarHelper::DEFAULT_OPTIONS
.except(:default, :rating, :ssl).merge(options)
+ else
+ nil
end
else
''