intridea/omniauth — Issue #543: Omniauth 1.0 parameter passing 
Author: dalyons
Created: 2011-11-23 02:42:17+00:00
State: open

As far as I can tell, there is a bug in omniauth master relating to passing params through to the callback stage.

AFAIK, the flow should go like this:
Go to `/auth/facebook?some=param`
Auth successfully
inside the `/auth/facebook/callback` action, I should have the params available in `request.env['omniauth.params']`

it doesnt work ATM, omniauth.params is always empty hash.

inside _lib/omniauth/strategy:196_ the query params are retrieved from the session:
```ruby
@env['omniauth.params'] = session.delete('query_params') || {}
```
But the only place `query_params` is ever set is in the mock request handler - it is never populated in real auth flows.

Thus we are in the odd situation where all our tests pass params correctly, but not in production :P

Pull request coming shortly.