Class: BacklogKit::Response::Middleware

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

Direct Known Subclasses

FileParser, RaiseError

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#bodyObject (readonly)

Returns the value of attribute body.



4
5
6
# File 'lib/backlog_kit/response/middleware.rb', line 4

def body
  @body
end

#headersObject (readonly)

Returns the value of attribute headers.



4
5
6
# File 'lib/backlog_kit/response/middleware.rb', line 4

def headers
  @headers
end

#statusObject (readonly)

Returns the value of attribute status.



4
5
6
# File 'lib/backlog_kit/response/middleware.rb', line 4

def status
  @status
end

Instance Method Details

#on_complete(env) ⇒ Object



6
7
8
9
10
# File 'lib/backlog_kit/response/middleware.rb', line 6

def on_complete(env)
  @headers = env.response_headers
  @status  = env.status
  @body    = env.body
end