aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_view/helpers/form_tag_helper.rb
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2012-02-21 09:06:40 -0800
committerAaron Patterson <aaron.patterson@gmail.com>2012-02-21 09:06:40 -0800
commitfd74cd78885080b00722749c4746a0aefd897e5c (patch)
tree6e665acff40441b0aaf6b87bdcfc428e3a397ce3 /actionpack/lib/action_view/helpers/form_tag_helper.rb
parent92a7296a5deb109d054b32d96fa1a74f0859a81b (diff)
parentc0ec40c83a7e2370f0f4a01055aafb69026d8099 (diff)
downloadrails-fd74cd78885080b00722749c4746a0aefd897e5c.tar.gz
rails-fd74cd78885080b00722749c4746a0aefd897e5c.tar.bz2
rails-fd74cd78885080b00722749c4746a0aefd897e5c.zip
Merge pull request #5116 from rubenfonseca/delete_with_block_refactor
Refactored two methods to use delete with a block
Diffstat (limited to 'actionpack/lib/action_view/helpers/form_tag_helper.rb')
-rw-r--r--actionpack/lib/action_view/helpers/form_tag_helper.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/form_tag_helper.rb b/actionpack/lib/action_view/helpers/form_tag_helper.rb
index 53fd189c39..2cf1c9055c 100644
--- a/actionpack/lib/action_view/helpers/form_tag_helper.rb
+++ b/actionpack/lib/action_view/helpers/form_tag_helper.rb
@@ -313,7 +313,7 @@ module ActionView
options["cols"], options["rows"] = size.split("x") if size.respond_to?(:split)
end
- escape = options.key?("escape") ? options.delete("escape") : true
+ escape = options.delete("escape") { true }
content = ERB::Util.html_escape(content) if escape
content_tag :textarea, content.to_s.html_safe, { "name" => name, "id" => sanitize_to_id(name) }.update(options)