Class: MooMoo::ParseOpenSRS

Inherits:
Faraday::Response::Middleware
  • Object
show all
Defined in:
lib/moo_moo/middleware/parse_open_srs.rb

Instance Method Summary (collapse)

Instance Method Details

- (Object) on_complete(env)



4
5
6
# File 'lib/moo_moo/middleware/parse_open_srs.rb', line 4

def on_complete(env)
  env[:body] = parse_response(env[:body])
end

- (Object) response_values(env)



8
9
10
# File 'lib/moo_moo/middleware/parse_open_srs.rb', line 8

def response_values(env)
  {:status => env[:status], :headers => env[:response_headers], :body => env[:body]}
end