Class: Librato::Metrics::Middleware::RequestBody

Inherits:
Faraday::Response::Middleware
  • Object
show all
Defined in:
lib/librato/metrics/middleware/request_body.rb

Instance Method Summary collapse

Instance Method Details

#call(env) ⇒ Object


7
8
9
10
11
12
# File 'lib/librato/metrics/middleware/request_body.rb', line 7

def call(env)
  # duplicate request body so it is preserved through request
  # in case we need it for exception output
  env[:request_body] = env[:body]
  @app.call(env)
end