I''m doing a typical logout type method def logout session[:user] = nil end Where the session is being magically restored. E.g. the user isn''t being logged out. I''m rather baffled- anyone have any thoughts? This is Windows or Unix, Rails 0.13.1 or 0.14.2, and ActiveRecordStore for sessions. Thanks, Nick -- Nicholas Van Weerdenburg
Hi ! 2005/11/4, Nicholas Van Weerdenburg <vanweerd@gmail.com>:> def logout > session[:user] = nil > endAdd a session.reset_session, which deletes the session: http://api.rubyonrails.com/classes/ActionController/Base.html#M000175 Of course, that would prevent storing anything in the flash, and if you had put stuff there that you wanted to keep... Hope that helps, François _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
On 11/4/05, Francois Beausoleil <francois.beausoleil-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi ! > > 2005/11/4, Nicholas Van Weerdenburg <vanweerd-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>: > > def logout > > session[:user] = nil > > end > > Add a session.reset_session, which deletes the session: > http://api.rubyonrails.com/classes/ActionController/Base.html#M000175 > > Of course, that would prevent storing anything in the flash, and if > you had put stuff there that you wanted to keep... > > Hope that helps, > François > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >Treid reset_session in my controller. Doesn''t do it either. Something fishy must be going on. I had another issue where if I called render_component_as_string via a before_filter on my login method, my new user session was lost on redirect. Maybe the issues are related somehow. Thanks, Nick -- Nicholas Van Weerdenburg
Hey- it started working. Thanks! On 11/4/05, Francois Beausoleil <francois.beausoleil-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi ! > > 2005/11/4, Nicholas Van Weerdenburg <vanweerd-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>: > > def logout > > session[:user] = nil > > end > > Add a session.reset_session, which deletes the session: > http://api.rubyonrails.com/classes/ActionController/Base.html#M000175 > > Of course, that would prevent storing anything in the flash, and if > you had put stuff there that you wanted to keep... > > Hope that helps, > François > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >-- Nicholas Van Weerdenburg