On Mon, Feb 13, 2012 at 7:42 PM, Colin Law <clan...@googlemail.com> wrote: > On 13 February 2012 13:58, Amrit Pal Pathak <amritpalpath...@gmail.com> wrote: >> script/server gives the following error. >> >> => Booting WEBrick >> => Rails 2.3.8 application starting on http://0.0.0.0:3000 >> /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support/dependencies.rb:105:in >> `const_missing': uninitialized constant User::Authentication >> (NameError) >> from /home/amrit/public_html/OSV/OpenStreetView/app/models/user.rb:4 > > Amrit, you have been asking questions here long enough by now to know > that if you get an error from your code saying a problem at user.rb > line 4 that showing us the first few lines of that file may be > helpful. require 'digest/sha1'
class User < ActiveRecord::Base include Authentication include Authentication::ByPassword include Authentication::ByCookieToken include Authorization::AasmRoles validates_presence_of :login validates_length_of :login, :within => 3..40 validates_uniqueness_of :login validates_format_of :login, :with => Authentication.login_regex, :message => Authentication.bad_login_message validates_format_of :name, :with => Authentication.name_regex, :message => Authentication.bad_name_message, :allow_nil => true validates_length_of :name, :maximum => 100 validates_presence_of :email validates_length_of :email, :within => 6..100 #r...@a.wk validates_uniqueness_of :email validates_format_of :email, :with => Authentication.email_regex, :message => Authentication.bad_email_message -- Thanks Regards Amrit Pal amritpalpathak.blogspot.com -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.