I try to implement facebook authentication in my application after this guide
After logging in to Facebook, I get the following:
Unknown action The action 'facebook' could not be found for Devise::OmniauthCallbacksController
I have a method implemented in application / controller / users / omniauth_callbacks_controller.rb as:
class Users::OmniauthCallbacksController < Devise::OmniauthCallbacksController def facebook
My callback route:
devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" }
Is there something I am missing? How can I debug this?
Thanks!
Update: added output of rake routes (sorry for the length):
new_user_session GET /users/sign_in(.:format) devise/sessions#new user_session POST /users/sign_in(.:format) devise/sessions#create destroy_user_session DELETE /users/sign_out(.:format) devise/sessions#destroy user_omniauth_authorize /users/auth/:provider(.:format) devise/omniauth_callbacks#passthru {:provider=>/facebook/} user_omniauth_callback /users/auth/:action/callback(.:format) devise/omniauth_callbacks#(?-mix:facebook) user_password POST /users/password(.:format) devise/passwords#create new_user_password GET /users/password/new(.:format) devise/passwords#new edit_user_password GET /users/password/edit(.:format) devise/passwords#edit PUT /users/password(.:format) devise/passwords#update cancel_user_registration GET /users/cancel(.:format) devise/registrations#cancel user_registration POST /users(.:format) devise/registrations#create new_user_registration GET /users/sign_up(.:format) devise/registrations#new edit_user_registration GET /users/edit(.:format) devise/registrations#edit PUT /users(.:format) devise/registrations#update DELETE /users(.:format) devise/registrations#destroy help /help(.:format) static_pages#help about /about(.:format) static_pages#about contact /contact(.:format) static_pages#contact users_new GET /users/new(.:format) users#new signup /signup(.:format) users#new new_certificate /new_certificate(.:format) users#newcertificate users GET /users(.:format) users#index POST /users(.:format) users#create new_user GET /users/new(.:format) users#new edit_user GET /users/:id/edit(.:format) users#edit user GET /users/:id(.:format) users
source share