mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Load XML Builder if it is not available
This commit is contained in:
parent
6f6f4e40ab
commit
e7514dc670
1 changed files with 1 additions and 1 deletions
|
@ -73,7 +73,7 @@ class Hash
|
||||||
# configure your own builder with the <tt>:builder</tt> option. The method also accepts
|
# configure your own builder with the <tt>:builder</tt> option. The method also accepts
|
||||||
# options like <tt>:dasherize</tt> and friends, they are forwarded to the builder.
|
# options like <tt>:dasherize</tt> and friends, they are forwarded to the builder.
|
||||||
def to_xml(options = {})
|
def to_xml(options = {})
|
||||||
require "active_support/builder" unless defined?(Builder)
|
require "active_support/builder" unless defined?(Builder) && defined?(Builder::XmlMarkup)
|
||||||
|
|
||||||
options = options.dup
|
options = options.dup
|
||||||
options[:indent] ||= 2
|
options[:indent] ||= 2
|
||||||
|
|
Loading…
Reference in a new issue