]> source.dussan.org Git - redmine.git/commitdiff
Enable SSL gravatars when Redmine is using https. (#2718)
authorEric Davis <edavis@littlestreamsoftware.com>
Sun, 2 Aug 2009 04:19:49 +0000 (04:19 +0000)
committerEric Davis <edavis@littlestreamsoftware.com>
Sun, 2 Aug 2009 04:19:49 +0000 (04:19 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2833 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/helpers/application_helper.rb

index 573d49c456cba05082e53a348af20c6d139ee2fb..f1b088c4a64b4518c9bdd3aa37363f03825bfdda 100644 (file)
@@ -626,6 +626,7 @@ module ApplicationHelper
   # +user+ can be a User or a string that will be scanned for an email address (eg. 'joe <joe@foo.bar>')
   def avatar(user, options = { })
     if Setting.gravatar_enabled?
+      options.merge!({:ssl => Setting.protocol == 'https'})
       email = nil
       if user.respond_to?(:mail)
         email = user.mail