Sha256: 2b8631ee52568e797f0cd460d2c2c8dd66dba97b92f174ea4d3515cef6bed992
Contents?: true
Size: 554 Bytes
Versions: 44
Compression:
Stored size: 554 Bytes
Contents
module Bandwidth module Voice module XmlVerb def initialize(data = nil) @data = (data || {}).clone() end def method_missing(name, *args, &block) if name[name.size - 1] == '=' @data[name[0..-2].to_sym] = args[0] else @data[name] end end def compact_hash(hash) hash.inject({}) do |new_hash, (k,v)| if !v.nil? new_hash[k] = v.class == Hash ? compact_hash(v) : v end new_hash end end end end end
Version data entries
44 entries across 44 versions & 1 rubygems