Sha256: 7dffc50b3729da166077b28a93a6143aa6b1be084ffae0cf49ea71e5d73ac278
Contents?: true
Size: 461 Bytes
Versions: 21
Compression:
Stored size: 461 Bytes
Contents
# encoding: utf-8 require 'faraday' module BitBucket class Response::Mashify < Response dependency 'hashie/mash' define_parser do |body| ::Hashie::Mash.new body end def parse(body) case body when Hash self.class.parser.call body when Array body.map { |item| item.is_a?(Hash) ? self.class.parser.call(item) : item } else body end end end # Response::Mashify end # BitBucket
Version data entries
21 entries across 21 versions & 5 rubygems