diff --git a/actionpack/lib/action_view/helpers/form_tag_helper.rb b/actionpack/lib/action_view/helpers/form_tag_helper.rb index a91e86f4db9c8c83ba7410cca3df4f9b8c93b127..5c1a4ae483123cd00537cb068e5edf395458899c 100644 --- a/actionpack/lib/action_view/helpers/form_tag_helper.rb +++ b/actionpack/lib/action_view/helpers/form_tag_helper.rb @@ -611,8 +611,8 @@ def html_options_for_form(url_for_options, options, *parameters_for_url) end def extra_tags_for_form(html_options) - snowman_tag = tag(:input, :type => "hidden", - :name => "utf8", :value => "✓".html_safe) + utf8_enforcer = tag(:input, :type => "hidden", + :name => "utf8", :value => "✓".html_safe) authenticity_token = html_options.delete("authenticity_token") method = html_options.delete("method").to_s @@ -629,7 +629,7 @@ def extra_tags_for_form(html_options) tag(:input, :type => "hidden", :name => "_method", :value => method) + token_tag(authenticity_token) end - tags = snowman_tag << method_tag + tags = utf8_enforcer << method_tag content_tag(:div, tags, :style => 'margin:0;padding:0;display:inline') end diff --git a/actionpack/test/template/form_helper_test.rb b/actionpack/test/template/form_helper_test.rb index 5296556fe6c05d7835b58c95a0aeb3accebb09bd..0507045ad2f0dfafff80c19a5bd87491f5b69118 100644 --- a/actionpack/test/template/form_helper_test.rb +++ b/actionpack/test/template/form_helper_test.rb @@ -1890,7 +1890,7 @@ def test_form_for_with_labelled_builder assert_dom_equal expected, output_buffer end - def snowman(method = nil) + def hidden_fields(method = nil) txt = %{