module Grape::Formatter::Xml
Public Class Methods
call(object, _env)
click to toggle source
# File lib/grape/formatter/xml.rb, line 5 def call(object, _env) return object.to_xml if object.respond_to?(:to_xml) fail Grape::Exceptions::InvalidFormatter.new(object.class, 'xml') end