[Git][noosfero/noosfero][master] should not escape body content in display content block

Leandro Nunes gitlab at mg.gitlab.com
Fri May 13 21:20:04 BRT 2016


Leandro Nunes pushed to branch master at Noosfero / noosfero


Commits:
41eb68c3 by Leandro Nunes dos Santos at 2016-05-13T21:19:47-03:00
should not escape body content in display content block

- - - - -


1 changed file:

- plugins/display_content/lib/display_content_block.rb


Changes:

=====================================
plugins/display_content/lib/display_content_block.rb
=====================================
--- a/plugins/display_content/lib/display_content_block.rb
+++ b/plugins/display_content/lib/display_content_block.rb
@@ -161,7 +161,7 @@ class DisplayContentBlock < Block
                 read_more_section = content_tag('div', link_to(_('Read more'), item.url), :class => 'read_more')
               end
             when 'body'
-              content_sections += (block.display_section?(section) ? (content_tag('div', item.body ,:class => 'body')) : '' )
+              content_sections += (block.display_section?(section) ? (content_tag('div', item.body.html_safe ,:class => 'body')) : '' )
             when 'image'
               image_section = image_tag item.image.public_filename if item.image
               if !image_section.blank?



View it on GitLab: https://gitlab.com/noosfero/noosfero/commit/41eb68c3fab6c532bae418f8621cfd67e09357bc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listas.softwarelivre.org/pipermail/noosfero-dev/attachments/20160514/100e4b10/attachment.html>


More information about the Noosfero-dev mailing list