Don't let user put HTML in alt and title image attribute of avatar
This commit is contained in:
parent
7796776135
commit
293445225a
1 changed files with 1 additions and 1 deletions
|
|
@ -124,7 +124,7 @@ module ApplicationHelper
|
|||
end
|
||||
|
||||
def person_image_tag(person, size=:thumb_small)
|
||||
"<img alt='#{person.name}' class='avatar' data-person_id='#{person.id}' src='#{image_or_default(person, size)}' title='#{person.name}'>".html_safe
|
||||
"<img alt=\"#{h(person.name)}\" class=\"avatar\" data-person_id=\"#{person.id}\" src=\"#{image_or_default(person, size)}\" title=\"#{h(person.name)}\">".html_safe
|
||||
end
|
||||
|
||||
def person_link(person)
|
||||
|
|
|
|||
Loading…
Reference in a new issue