diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2006-08-20 14:38:58 +0000 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2006-08-20 14:38:58 +0000 |
commit | edb42088571f9ad61908032c3df12b4700e099e9 (patch) | |
tree | f806b2d7dd3d2b855ed81698b9bad69ceefd0d78 /activerecord/lib | |
parent | 04d2d5f2884677542b7062ece98bd91978e78b2b (diff) | |
download | rails-edb42088571f9ad61908032c3df12b4700e099e9.tar.gz rails-edb42088571f9ad61908032c3df12b4700e099e9.tar.bz2 rails-edb42088571f9ad61908032c3df12b4700e099e9.zip |
to_xml: correct naming of included associations. Closes #5831.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4794 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/xml_serialization.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/xml_serialization.rb b/activerecord/lib/active_record/xml_serialization.rb index 5324ae5a0a..2e4a038886 100644 --- a/activerecord/lib/active_record/xml_serialization.rb +++ b/activerecord/lib/active_record/xml_serialization.rb @@ -190,7 +190,7 @@ module ActiveRecord #:nodoc: tag = tag.dasherize if dasherize? builder.tag!(tag) do - records.each { |r| r.to_xml(opts) } + records.each { |r| r.to_xml(opts.merge(:root => association.to_s.singularize)) } end end when :has_one, :belongs_to |