diff --git a/lib/models/change.js b/lib/models/change.js index 1fc8e72c..bd51faac 100644 --- a/lib/models/change.js +++ b/lib/models/change.js @@ -15,7 +15,7 @@ var PersistedModel = require('./persisted-model') */ var properties = { - id: {type: String, generated: true, id: true}, + id: {type: String, id: true}, rev: {type: String}, prev: {type: String}, checkpoint: {type: Number}, diff --git a/test/change.test.js b/test/change.test.js index 4c34eace..53bdcec9 100644 --- a/test/change.test.js +++ b/test/change.test.js @@ -84,6 +84,7 @@ describe('Change', function(){ it('should create an entry', function (done) { var test = this; Change.findById(this.result.id, function(err, change) { + if (err) return done(err); assert.equal(change.id, test.result.id); done(); });