Rails: how to redirect to a specific page after signing out with devise -


i have question using devise in rails. how can redirect specific page after signing out (destroying user session)?

i tried following in application controller, not seem working:

  def after_sign_out_path_for(resource_or_scope)     root_path    end 

thanks in advance!

that should work according wiki.

maybe you've missed last line:

you should override method devise::controllers::helpers#stored_location_for in application controller, return nil. applies after_sign_in_path_for also. ymmv.


Comments

Popular posts from this blog

c# - SVN Error : "svnadmin: E205000: Too many arguments" -

c# - Copy ObservableCollection to another ObservableCollection -

All overlapping substrings matching a java regex -