module CongressApi::MashedParser

Protected Instance Methods

json() click to toggle source
Calls superclass method
# File lib/congress_api/mashed_parser.rb, line 5
def json
  mashed(super)
end

Private Instance Methods

mashed(thing) click to toggle source
# File lib/congress_api/mashed_parser.rb, line 10
def mashed thing
  if thing.is_a? Hash
    Hashie::Mash.new thing
  elsif thing.is_a? Array
    thing.map &method(:mashed)
  else
    thing
  end
end