From e4527856ad10794568261bc333d8ab3eecc22e39 Mon Sep 17 00:00:00 2001 From: Dombi Attila Date: Tue, 26 Jun 2012 15:44:57 +0300 Subject: [PATCH] The updateAttribute callback doesn't behaves as its described. It should send the object instance alongside the error too. --- lib/abstract-class.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/abstract-class.js b/lib/abstract-class.js index bf540321..26863475 100644 --- a/lib/abstract-class.js +++ b/lib/abstract-class.js @@ -577,7 +577,7 @@ AbstractClass.prototype.updateAttributes = function updateAttributes(data, cb) { inst.isValid(function (valid) { if (!valid) { if (cb) { - cb(new Error('Validation error')); + cb(new Error('Validation error'), inst); } } else { update();