pengwynn/faraday_middleware — pull request #38 by mrmicahcooper (2012-04-29 13:54:37+00:00)
Title: Keep cookies through a redirection

I added another option to the follow redirection allowing you to keep selected cookies through the requests.

Example:
```
conn = Faraday.new 'https://example.com/' do |c|
c.use FaradayMiddleware::FollowRedirects, limit: 3, cookies: ['cookie1', 'cookie2']
end
```

or if you want to keep all the cookies

```
conn = Faraday.new 'https://example.com/' do |c|
c.use FaradayMiddleware::FollowRedirects, limit: 3, :cookies => :all
end
```