mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
822c41d69d
[#2084 state:committed] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
21 lines
No EOL
418 B
Ruby
21 lines
No EOL
418 B
Ruby
# = XmlMini
|
|
module ActiveSupport
|
|
module XmlMini
|
|
extend self
|
|
|
|
CONTENT_KEY = '__content__'.freeze
|
|
|
|
# Hook the correct parser into XmlMini
|
|
def hook_parser
|
|
begin
|
|
require 'xml/libxml' unless defined? LibXML
|
|
require "active_support/xml_mini/libxml.rb"
|
|
rescue MissingSourceFile => e
|
|
require "active_support/xml_mini/rexml.rb"
|
|
end
|
|
end
|
|
|
|
hook_parser
|
|
|
|
end
|
|
end |