module Garage::ResourceCastingResponder
Public Class Methods
new(*args)
click to toggle source
Calls superclass method
# File lib/garage/resource_casting_responder.rb, line 2 def initialize(*args) super @caster = Garage.configuration.cast_resource end
Public Instance Methods
display(resource, given_options={})
click to toggle source
Calls superclass method
# File lib/garage/resource_casting_responder.rb, line 7 def display(resource, given_options={}) if @caster resource = @caster.call(resource, @options) end super(resource, given_options) end