Fix updateAll callback in "transient" connector

Fix the implementation to return an object as the result,
that's the expected API since 04f35b3.
This commit is contained in:
Miroslav Bajtoš 2015-03-20 08:34:58 +01:00
parent 84448bb0dc
commit 94e6d893a7
1 changed files with 2 additions and 2 deletions

View File

@ -98,7 +98,7 @@ Transient.prototype.save = function save(model, data, callback) {
Transient.prototype.update =
Transient.prototype.updateAll = function updateAll(model, where, data, cb) {
var count = 0;
this.flush('update', count, cb);
this.flush('update', {count: count}, cb);
};
Transient.prototype.updateAttributes = function updateAttributes(model, id, data, cb) {
@ -110,7 +110,7 @@ Transient.prototype.updateAttributes = function updateAttributes(model, id, data
throw err;
}
}
this.setIdValue(model, data, id);
this.save(model, data, cb);
};