diff --git a/lib/jenkins_api_client/client.rb b/lib/jenkins_api_client/client.rb index cee4c2cb..054f9c28 100644 --- a/lib/jenkins_api_client/client.rb +++ b/lib/jenkins_api_client/client.rb @@ -369,6 +369,7 @@ def make_http_request(request, follow_redirect = @follow_redirects) http.read_timeout = @http_read_timeout response = http.request(request) + @cookies = response["set-cookie"] case response when Net::HTTPRedirection then # If we got a redirect request, follow it (if flag set), but don't