GeoRSS aggregator and Layar augmented reality server
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 
 
 
 

19 lignes
567 B

  1. class User
  2. include MongoMapper::Document
  3. key :email, String
  4. key :crypted_password, String
  5. key :salt, String
  6. timestamps!
  7. authenticates_with_sorcery!
  8. # attr_accessible :email, :password, :password_confirmation
  9. validates_presence_of :email
  10. validates_presence_of :password, :on => :create
  11. validates_uniqueness_of :email
  12. validates_length_of :password, :minimum => 3, :message => "password must be at least 3 characters long", :if => :password
  13. validates_confirmation_of :password, :message => "should match confirmation", :if => :password
  14. end