I think I see the problem. The docs imply that you can run the generate with --include-activation at some point
after you've run it once, but at least in my case, that
failed to update the migration file, which means my
users table is wrong.
        -glenn

Glenn Little wrote:
I'm starting to experiment with Restful Authentication.  Got
the basic (no activation) mode working, but when I try to add
the activation, it breaks. What I did:

 * pass the --include-activation flag to the generator
 * configure the observer in environment.rb:
     config.active_record.observers = :user_observer

However, when I try to create a new user, I get:
undefined method `activation_code=' for #<User:0xb76c17ec>

The only place I see "activation_code=" is in the generated
model code, user.rb.  There is this, in the protected
section:

protected
 def make_activation_code    # (a before_create filter)
   self.activation_code = Digest::SHA1....<args etc>
 end


My questions are:

 * what is the syntax "self.blah=" doing?  Why is "self" used?

 * is this missing an attr_accessor or something?

 * anyone else have this problem, and know what I may have done
   incorrectly?  Seemed simple, just install the plugin and run
   the generator, but...

Thanks.

        -glenn
_______________________________________________
Sdruby mailing list
[email protected]
http://lists.sdruby.com/mailman/listinfo/sdruby
_______________________________________________
Sdruby mailing list
[email protected]
http://lists.sdruby.com/mailman/listinfo/sdruby

Reply via email to