45 46 47 48 49 50 51
# File 'lib/pipl/errors.rb', line 45 def self.from_http_response(resp) begin self.deserialize(resp.body, resp) rescue Pipl::Client::APIError.new resp.message, resp.code end end