I have devise and cancan set up and I'm having trouble redirecting users to a certain page after registration.
class RegistrationsController < Devise::RegistrationsController
def after_sign_up_path_for(resource)
"http://google.com"
end
end
then in my routes:
authenticated :user do
root :to => "dashboard#show"
end
Now when I sign up a user, it just gets directed to the dashboard#show. I'm trying to make it go to google.com, but it doesn't. Am I doing something wrong? Or is there another way to redirect users after signing up when using CanCan?
Thanks