Sha256: 2ef386b7ee26fd4d43174b6a86db88c82c88880603ff4d791fef6d1bb4e7cf31
Contents?: true
Size: 550 Bytes
Versions: 12
Compression:
Stored size: 550 Bytes
Contents
module Almodovar module ToXml def to_xml(options = {}, &block) return super(options, &block) if !options[:convert_links] || options.delete(:skip_links_one_level) options[:builder].tag!(:link, rel: options[:root]) do |xml| super options.merge(skip_links_one_level: self.is_a?(Array)), &block end end end class Resource def to_xml(options = {}) options[:builder].tag!(:link, rel: options[:root], href: url) end end end Array.send :prepend, Almodovar::ToXml Hash.send :prepend, Almodovar::ToXml
Version data entries
12 entries across 12 versions & 1 rubygems