From f4e3d571a33f6e7eb780ebc5f2c7dd1da4f7f8ad Mon Sep 17 00:00:00 2001 From: barisusakli Date: Mon, 15 Aug 2016 19:26:18 +0300 Subject: [PATCH] shorter --- src/database/mongo/sorted.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/database/mongo/sorted.js b/src/database/mongo/sorted.js index a262ff9984..1f9a67adb1 100644 --- a/src/database/mongo/sorted.js +++ b/src/database/mongo/sorted.js @@ -625,9 +625,7 @@ module.exports = function(db, module) { limit = 0; } - var pipeline = []; - - pipeline.push({ $match: { _key: {$in: sets}} }); + var pipeline = [{ $match: { _key: {$in: sets}} }]; weights.forEach(function(weight, index) { if (weight !== 1) {