mkdynamic/omniauth-facebook — pull request #19 by GermanDZ (2011-12-22 12:17:04+00:00)
Title: Add 'state' to authorization params.

More information on https://developers.facebook.com/docs/reference/dialogs/oauth/

The facebook's implementation of OAuth, allows to pass only one special parameter wich will be passed back in the callback.

This is useful because, you can manage the server side response.

I am using it in Rails 3 app, in the "omniauth controller" for Devise. I pass "popup" as value to "state", so when I receive the callback, I can respond with a different partial than when is called "full screen".