This project is archived and is in readonly mode.
[PATCH] 2.3.2 text_area_tag calling stringify_keys two times
Reported by Gabriel Sobrinho | April 30th, 2009 @ 07:59 PM
Hello,
The text_area_tag is calling stringify_keys 2 times unnecessary. See:
def text_area_tag(name, content = nil, options = {})
options.stringify_keys!
if size = options.delete("size")
options["cols"], options["rows"] = size.split("x") if size.respond_to?(:split)
end
content_tag :textarea, content, { "name" => name, "id" => name }.update(options.stringify_keys)
end
The first time, the method is called to self instance and second time is called again (unnecessary).
Thank you
Comments and changes to this ticket
-
CancelProfileIsBroken August 6th, 2009 @ 02:20 PM
- Tag changed from 2.3.2, action_view to 2.3.2, action_view, bugmash
-
Rizwan Reza August 7th, 2009 @ 08:13 PM
+1 verified. I removed the second method call to stringify_keys in the second last line and verified that all the tests still pass.
-
Steve St. Martin August 8th, 2009 @ 01:08 AM
+1 verified. I removed second call to stringify_keys on line 265, I've attached a patch all tests still pass
-
Steve St. Martin August 8th, 2009 @ 02:52 AM
- Title changed from 2.3.2 text_area_tag calling stringify_keys two times to [PATCH] 2.3.2 text_area_tag calling stringify_keys two times
-
Elad Meidar August 8th, 2009 @ 03:42 AM
+1 verified, patch added to test app and a mini app, both pass completely as well as Rails tests.
-
Repository August 8th, 2009 @ 02:01 PM
(from [a8645593a4446a89b2e699e153adca968340581a]) remove duplicate call to stringify_keys [#2587 status:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/a8645593a4446a89b2e699e153adca... -
CancelProfileIsBroken August 8th, 2009 @ 08:38 PM
- State changed from new to resolved
-
CancelProfileIsBroken August 8th, 2009 @ 11:07 PM
- Tag changed from 2.3.2, action_view, bugmash to 2.3.2, action_view
- Milestone cleared.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Tags
Referenced by
- 2587 [PATCH] 2.3.2 text_area_tag calling stringify_keys two times (from [a8645593a4446a89b2e699e153adca968340581a]) remove ...