Logout error rails 2.3

1 view
Skip to first unread message

lardawge

unread,
Feb 7, 2009, 3:46:53 PM2/7/09
to Ruby on Rails: Goldberg
I get an error when logging out which has to do with line 109
(session.delete) in auth_controller... number of arguments. If I
comment it out it works fine but I am not sure why it is set up this
way to begin with. It seems like overkill since the very next line
clears the session anyway... Am I missing something? Also shouldn't
it
be "reset_session" instead?

I would think getting rid of this:

def logout
if request.post?
self.class.logout(session)
end
redirect_to Goldberg.settings.public_role.get_start_path
end
protected
def self.logout(session)
session[:goldberg] = nil
end
def self.clear_session(session)
session[:goldberg] = nil
end

for this:

def logout
if request.post?
reset_session
end
redirect_to Goldberg.settings.public_role.get_start_path
end

Less code... Reasons it won't work?

Jej

unread,
Feb 8, 2009, 3:08:04 PM2/8/09
to Ruby on Rails: Goldberg
> I get an error when logging out which has to do with line 109
> (session.delete) in auth_controller... number of arguments. If I
> comment it out it works fine but I am not sure why it is set up this
> way to begin with. It seems like overkill since the very next line
> clears the session anyway... Am I missing something? Also shouldn't
> it
> be "reset_session" instead?

I applied the same remedy! And as you I don't understand the purpose
of this delete on the session.

Where are Goldberg gurus??

Jej

Ahsan Ali

unread,
Feb 8, 2009, 10:52:58 PM2/8/09
to rubyonrail...@googlegroups.com
Well, its possible that changes have to be made for it to be compatible with Rails 2.3.

Jej

unread,
Feb 9, 2009, 3:48:19 PM2/9/09
to Ruby on Rails: Goldberg

> Well, its possible that changes have to be made for it to be compatible with
> Rails 2.3.
>

The session.delete is the lonely problem I encountered with Goldberg
and Rails 2.3! This plugin is incredibly stable, thinking that it
relies on rails low level functions...

That's a pity that so few people are contributing around here.

Jej
Reply all
Reply to author
Forward
0 new messages