views:

539

answers:

1

Hi I am using Devise 1.0.3 and Rails 2.3.5

My user has the following devise line:

devise :authenticatable, :confirmable, :recoverable, :registerable, 
     :rememberable, :trackable, :validatable

I would like to customize where the application redirects the user to, after requesting instructions for a password reset.

For other registrations devise provides after_sign_in_path_for and after_sign_out_path_for But I have not found an equivalent for the recoverable module.

Whats the best way to accomplish this?

A: 

From a quick flip through the code it seems to be explicitly set in the controller where you could override the method it uses to redirect, however I would guess this is likely to break other areas of code or require special handling.

The easier solution I'd imagine would be to follow the readme instructions for customising the controller to redirect to your preferred path. I've done something similar on the invitable module to fit within my application.

David Lyod