More html_safe strings now use the safe_concat method
[#3856 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
This commit is contained in:
parent
c65f4b1ffb
commit
e115eb097e
|
@ -309,7 +309,7 @@ module ActionView
|
||||||
|
|
||||||
options[:html][:remote] = true if options.delete(:remote)
|
options[:html][:remote] = true if options.delete(:remote)
|
||||||
|
|
||||||
concat(form_tag(options.delete(:url) || {}, options.delete(:html) || {}))
|
safe_concat(form_tag(options.delete(:url) || {}, options.delete(:html) || {}))
|
||||||
fields_for(object_name, *(args << options), &proc)
|
fields_for(object_name, *(args << options), &proc)
|
||||||
safe_concat('</form>')
|
safe_concat('</form>')
|
||||||
end
|
end
|
||||||
|
|
|
@ -441,8 +441,8 @@ module ActionView
|
||||||
# # => <fieldset class="format"><p><input id="name" name="name" type="text" /></p></fieldset>
|
# # => <fieldset class="format"><p><input id="name" name="name" type="text" /></p></fieldset>
|
||||||
def field_set_tag(legend = nil, options = nil, &block)
|
def field_set_tag(legend = nil, options = nil, &block)
|
||||||
content = capture(&block)
|
content = capture(&block)
|
||||||
concat(tag(:fieldset, options, true))
|
safe_concat(tag(:fieldset, options, true))
|
||||||
concat(content_tag(:legend, legend)) unless legend.blank?
|
safe_concat(content_tag(:legend, legend)) unless legend.blank?
|
||||||
concat(content)
|
concat(content)
|
||||||
safe_concat("</fieldset>")
|
safe_concat("</fieldset>")
|
||||||
end
|
end
|
||||||
|
@ -477,7 +477,7 @@ module ActionView
|
||||||
|
|
||||||
def form_tag_in_block(html_options, &block)
|
def form_tag_in_block(html_options, &block)
|
||||||
content = capture(&block)
|
content = capture(&block)
|
||||||
concat(form_tag_html(html_options))
|
safe_concat(form_tag_html(html_options))
|
||||||
concat(content)
|
concat(content)
|
||||||
safe_concat("</form>")
|
safe_concat("</form>")
|
||||||
end
|
end
|
||||||
|
|
|
@ -86,7 +86,7 @@ module ActionView
|
||||||
tag = content_tag(:script, javascript_cdata_section(content), html_options.merge(:type => Mime::JS))
|
tag = content_tag(:script, javascript_cdata_section(content), html_options.merge(:type => Mime::JS))
|
||||||
|
|
||||||
if block_called_from_erb?(block)
|
if block_called_from_erb?(block)
|
||||||
concat(tag)
|
safe_concat(tag)
|
||||||
else
|
else
|
||||||
tag
|
tag
|
||||||
end
|
end
|
||||||
|
|
|
@ -72,7 +72,7 @@ module ActionView
|
||||||
content_tag = content_tag_string(name, capture(&block), options, escape)
|
content_tag = content_tag_string(name, capture(&block), options, escape)
|
||||||
|
|
||||||
if block_called_from_erb?(block)
|
if block_called_from_erb?(block)
|
||||||
concat(content_tag)
|
safe_concat(content_tag)
|
||||||
else
|
else
|
||||||
content_tag
|
content_tag
|
||||||
end
|
end
|
||||||
|
|
|
@ -19,7 +19,7 @@ module ActionView
|
||||||
options[:locals] ||= {}
|
options[:locals] ||= {}
|
||||||
|
|
||||||
if block_given?
|
if block_given?
|
||||||
return concat(_render_partial(options.merge(:partial => layout), &block))
|
return safe_concat(_render_partial(options.merge(:partial => layout), &block))
|
||||||
elsif options.key?(:partial)
|
elsif options.key?(:partial)
|
||||||
return _render_partial(options)
|
return _render_partial(options)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue