Redirection of user after "sign in" in devise

I am using rails 3 and devise for user authentication.
Everything is working fine. But after the user gets login it is get
redirected to the application home page but I have to redirect it to the
admin page.
How can I do that?
I have tried this in my routes.rb file, but it has not worked at all.

" devise_for :users
match ‘/users’ => ‘admin#index’, :as => ‘user_root’
resources :admin

Can anyone tell me how should I fix this issue?


This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs