diff --git a/lib/abstract-class.js b/lib/abstract-class.js index 2ef7a6cf..da71b5ab 100644 --- a/lib/abstract-class.js +++ b/lib/abstract-class.js @@ -313,7 +313,6 @@ AbstractClass.all = function all(params, cb) { } var constr = this; this.schema.adapter.all(this.modelName, params, function (err, data) { - var collection = null; if (data && data.map) { data.forEach(function (d, i) { var obj = new constr; @@ -321,7 +320,7 @@ AbstractClass.all = function all(params, cb) { data[i] = obj; }); if (data && data.countBeforeLimit) { - collection.countBeforeLimit = data.countBeforeLimit; + data.countBeforeLimit = data.countBeforeLimit; } cb(err, data); } diff --git a/package.json b/package.json index a38e6ad8..eeb1be08 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "jugglingdb", "description": "ORM for every database: redis, mysql, neo4j, mongodb, postgres, sqlite", - "version": "0.1.23", + "version": "0.1.24-pre", "author": "Anatoliy Chakkaev ", "contributors": [ { "name": "Anatoliy Chakkaev", "email": "rpm1602@gmail.com" },