]> git.openstreetmap.org Git - rails.git/blobdiff - config/initializers/libxml.rb
Make the role in relations optional, with a test to make sure it is. Also start movin...
[rails.git] / config / initializers / libxml.rb
index 3b5919f0fca8c0a65c7a0f48f75d099f275bc4fa..ae636a9a31039a260539fd2d195fa49e9ce56684 100644 (file)
@@ -1,5 +1,9 @@
 # This is required otherwise libxml writes out memory errors to
 # the standard output and exits uncleanly 
 # This is required otherwise libxml writes out memory errors to
 # the standard output and exits uncleanly 
-LibXML::XML::Parser.register_error_handler do |message|
+# Changed method due to deprecation of the old register_error_handler
+# http://libxml.rubyforge.org/rdoc/classes/LibXML/XML/Parser.html#M000076
+# So set_handler is used instead
+# http://libxml.rubyforge.org/rdoc/classes/LibXML/XML/Error.html#M000334
+LibXML::XML::Error.set_handler do |message|
   raise message
 end
   raise message
 end