Re: [Rails] Re: routing issue, matching a param as action

2012-10-07 Thread Ignacio Piantanida
You could do something like this: match '/auth/:provider/callback', to: 'omniauth_callbacks#all_callbacks' class OmniauthCallbacksController def all_callbacks send(params[:provider]) end def facebook end def twitter ... end def method_missing(method_name, *args,

[Rails] Re: routing issue, matching a param as action

2012-10-07 Thread Erwin
It seems in some cases I can use the redirect match '/auth/:provider/callback', :to => redirect {|params| "/ omniauth_callbacks/#{params[:provider]}" } but not in this case , as the redirect will change the request , and I'll not be able to check for request.env["omniauth.auth"] so I resolv