From aee6d2ef63578204281fdc1e84409bfa769740dd Mon Sep 17 00:00:00 2001 From: Mitar Date: Sun, 20 Dec 2015 12:33:54 +0100 Subject: [PATCH] Allow to find the corresponding collection from the store. --- packages/mongo/collection.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/mongo/collection.js b/packages/mongo/collection.js index 885b7e1881..3154c27d39 100644 --- a/packages/mongo/collection.js +++ b/packages/mongo/collection.js @@ -209,6 +209,11 @@ Mongo.Collection = function (name, options) { getDoc: function(id) { return self.findOne(id); }, + + // To be able to get back to the collection from the store. + _getCollection: function () { + return self; + } }); if (!ok)