Rails Devise Confirmable - redirect -


the rails docs devise instructions how redirect incorrect:

https://github.com/plataformatec/devise/wiki/how-to:-add-:confirmable-to-users#redirecting-user

does know how this?

you need override devise confirmation controller. in routes.rb add line

devise_for :users, controllers: { confirmations: 'confirmations' } 

create file in , paste code

class confirmationscontroller < devise::confirmationscontroller    private    def after_confirmation_path_for(resource_name, resource)     your_new_after_confirmation_path #your path want land   end  end 

you may need restart server.

source : https://github.com/plataformatec/devise/wiki/how-to:-add-:confirmable-to-users#redirecting-user


Comments

Popular posts from this blog

testing - Detect whether test has failed within fixture -

AbotX : How do you create a parallel crawler that stays on and can be added to at run time from new requests -

android - Create single AAR file from multiple modules using Gradle -