uninitialized constant Authlogic

67 views
Skip to first unread message

Matt Garland

unread,
Aug 31, 2011, 12:56:02 PM8/31/11
to Authlogic
# Gemfile

gem "authlogic"

>> bundle install

Using authlogic (3.0.3)
Using rails (3.0.8)

>>UserSession.all

NameError: uninitialized constant Authlogic
from */app/models/user_session.rb:1

# user session

class UserSession < Authlogic::Session::Base
end

I can't get the rails project to access the gem. After googling, I
tried:

# in environment.rb

gem "authlogic"

# in an authlogic.rb initializer

require "authlogic"

>>rails s

LoadError: no such file to load -- authlogic

I saw that the plugin was recommended over the gem. Maybe I should try
that?

Thanks!

Matt

Matt Garland

unread,
Aug 31, 2011, 2:42:11 PM8/31/11
to Authlogic
Using the plugin worked! It'd be nice to have it in the gemfile, but I
can live with this.
Reply all
Reply to author
Forward
0 new messages