Permalink
Browse files

create a request::session object in the memecache store middleware

  • Loading branch information...
1 parent b13849d commit 638d0020a2ad92993cb9c7385ad7584618c7af1c @tenderlove tenderlove committed May 4, 2012
Showing with 10 additions and 0 deletions.
  1. +10 −0 actionpack/lib/action_dispatch/middleware/session/mem_cache_store.rb
@@ -12,6 +12,16 @@ def initialize(app, options = {})
options[:expire_after] ||= options[:expires]
super
end
+
+ private
+
+ def prepare_session(env)
+ Request::Session.create(self, env, @default_options)
+ end
+
+ def loaded_session?(session)
+ !session.is_a?(Request::Session) || session.loaded?
+ end
end
end
end

0 comments on commit 638d002

Please sign in to comment.