plataformatec/devise — Issue #1397: obsolete wiki and rdoc for after_sign_in_path_for ?
Author: Pepan
Created: 2011-10-21 10:18:19+00:00
State: open

recommended solution in links below does not work. (store_location_for(resource) is missing in session_controller)
https://github.com/plataformatec/devise/wiki/How-To:-Redirect-to-a-specific-page-on-successful-sign-in
http://rdoc.info/github/plataformatec/devise/master/Devise/Controllers/Helpers#after_sign_in_path_for-instance_method

but there is correct solution in source of ... devise-1.4.8/lib/devise/controlers/helpers.rb
# If the resource root path is not defined, root_path is used. However,
# if this default is not enough, you can customize it, for example:
#
# def after_sign_in_path_for(resource)
# if resource.is_a?(User) && resource.can_publish?
# publisher_url
# else
# super
# end
# end
#