Attributes
| root_request | [RW] |
returns the top-most original |
Public Instance methods
max_redirects()
[show source]
# File lib/httpx/plugins/follow_redirects.rb 218 def max_redirects 219 @options.max_redirects || MAX_REDIRECTS 220 end
redirect_request()
returns the follow-up redirect request, or itself
[show source]
# File lib/httpx/plugins/follow_redirects.rb 201 def redirect_request 202 @redirect_request || self 203 end
redirect_request=(req)
sets the follow-up redirect request
[show source]
# File lib/httpx/plugins/follow_redirects.rb 206 def redirect_request=(req) 207 @redirect_request = req 208 req.root_request = @root_request || self 209 @response = nil 210 end
response()
[show source]
# File lib/httpx/plugins/follow_redirects.rb 212 def response 213 return super unless @redirect_request && @response.nil? 214 215 @redirect_request.response 216 end