# Setup accessible (or protected) attributes for your model
attr_accessible :id, :name, :password, :password_confirmation, :remember_me , :email
- before_create do |r|
- r.build_author :name => 'no name'
- end
-
def create_token
self.ensure_authentication_token
self.save