escape gravatar URLs to comply with W3C standards

This fixes an HTML validation error due to & not being properly escaped on the gravatar URLs.
This commit is contained in:
Jaime Iniesta 2014-04-21 00:46:00 +02:00
parent 7aecf5f6ef
commit 6084cb969d
1 changed files with 1 additions and 1 deletions

View File

@ -332,7 +332,7 @@ class User < ActiveRecord::Base
def self.gravatar_template(email) def self.gravatar_template(email)
email_hash = self.email_hash(email) email_hash = self.email_hash(email)
"//www.gravatar.com/avatar/#{email_hash}.png?s={size}&r=pg&d=identicon" "//www.gravatar.com/avatar/#{email_hash}.png?s={size}&amp;r=pg&amp;d=identicon"
end end
# Don't pass this up to the client - it's meant for server side use # Don't pass this up to the client - it's meant for server side use