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