diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-04 15:43:17 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-04-04 15:43:17 +0000 |
commit | a87c1d4dd856d138e97e821083c905b481982399 (patch) | |
tree | b193f0ee0f5938c2233bf998483f082fb69fae41 | |
parent | d6901bfe93431127433b3c682bb97b2d6acd31cb (diff) | |
download | rails-a87c1d4dd856d138e97e821083c905b481982399.tar.gz rails-a87c1d4dd856d138e97e821083c905b481982399.tar.bz2 rails-a87c1d4dd856d138e97e821083c905b481982399.zip |
Made it possible to do text_field :account, :name in addition to text_field "account", "name"
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1088 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
-rw-r--r-- | actionpack/lib/action_view/helpers/form_helper.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_view/helpers/form_helper.rb b/actionpack/lib/action_view/helpers/form_helper.rb index 2f42a8a648..7333f4036d 100644 --- a/actionpack/lib/action_view/helpers/form_helper.rb +++ b/actionpack/lib/action_view/helpers/form_helper.rb @@ -149,7 +149,7 @@ module ActionView DEFAULT_DATE_OPTIONS = { :discard_type => true }.freeze unless const_defined?(:DEFAULT_DATE_OPTIONS) def initialize(object_name, method_name, template_object, local_binding = nil) - @object_name, @method_name = object_name, method_name + @object_name, @method_name = object_name.to_s, method_name.to_s @template_object, @local_binding = template_object, local_binding if @object_name.sub!(/\[\]$/,"") @auto_index = @template_object.instance_variable_get("@#{Regexp.last_match.pre_match}").id_before_type_cast |