asciinema.org/config/initializers/warden.rb

13 lines
275 B
Ruby
Raw Normal View History

2014-02-20 22:00:44 +00:00
Warden::Manager.serialize_into_session do |user|
user.id
end
Warden::Manager.serialize_from_session do |id|
User.find_by_id(id)
end
require 'auth_cookie_strategy'
Rails.application.config.middleware.insert_after ActionDispatch::Flash, Warden::Manager do |manager|
end