Added self.authenticate in user.rb.