This project is archived and is in readonly mode.

#6757 new
Bradley Harris

Hash.from_xml chokes on empty CDATA

Reported by Bradley Harris | April 29th, 2011 @ 07:25 PM

Rails 3.0.6 --

>> require 'rubygems'
=> false
>> gem 'activesupport', '3.0.6'
=> true
>> require 'active_support/all'
=> true
>> Hash.from_xml("<data><![CDATA[]]></data>")
=> {"data"=>""}

Rails 3.0.7 --

>> require 'rubygems'
=> false
>> gem 'activesupport', '3.0.7'
=> true
>> require 'active_support/all'
=> true
>> Hash.from_xml("<data><![CDATA[]]></data>")
=> {"data"=>{"__content__"=>""}}

Comments and changes to this ticket

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

Pages