]> source.dussan.org Git - redmine.git/commitdiff
Merged r17263 into 3.4-stable (#28208).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 7 Apr 2018 07:29:25 +0000 (07:29 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 7 Apr 2018 07:29:25 +0000 (07:29 +0000)
git-svn-id: http://svn.redmine.org/redmine/branches/3.4-stable@17264 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/helpers/application_helper.rb

index fd8da95d9c93b842b9ccf5c2614f5f49999f2706..792af987ca13b42ae3cc5f2db27c2e0528308893 100644 (file)
@@ -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
       ''