views:

55

answers:

1

See the full error here: http://notesapp.heroku.com/

I'm using DataMapper and dm-validations 0.10.2. No matter how much I tweak my models, I get the same error, or another one. Here's how my model looks like:

class User
    include DataMapper::Resource

    attr_accessor :password, :password_confirmation

    property :id, Serial, :required => true
    property :email, String, :required => true, :format => :email_address, :unique => true
    property :hashed_password, String
    property :salt, String, :required => true
    property :created_at, DateTime, :default => Time.now
    property :permission_level, Integer, :default => 1

    validates_present :password_confirmation, :unless => Proc.new { |t| t.hashed_password }
    validates_present :password, :unless => Proc.new { |t| t.hashed_password }
    validates_is_confirmed :password
+1  A: 

Looks like you have an old version of DataObjects (probably pre 0.10.0) installed. Please update to the latest version and I think this error will disappear. Depending on the database you use it's most likely either do_postgres or do_mysql you need to upgrade.

Dirkjan Bussink
Doesn't directly solve the problem, but steered me in the right way. Thanks.
Joel M.