Add exceptions for remaing cases where XML::Parser.string is used, to catch for empty strings.

See also r14241
This commit is contained in:
Thomas Wood 2009-04-09 22:37:43 +00:00
parent 9c0f288bb7
commit 6442208841
3 changed files with 8 additions and 2 deletions

View file

@ -70,7 +70,7 @@ class Node < ActiveRecord::Base
doc.find('//osm/node').each do |pt|
return Node.from_xml_node(pt, create)
end
rescue LibXML::XML::Error => ex
rescue LibXML::XML::Error, ArgumentError => ex
raise OSM::APIBadXMLError.new("node", xml, ex.message)
end
end