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