From 873c68966b2603df7deeb6eef5e7e658bfaca5fa Mon Sep 17 00:00:00 2001 From: Leonardo Venturini Date: Mon, 28 Oct 2024 09:07:32 -0400 Subject: [PATCH] remove underscore --- packages/mongo/asynchronous_cursor.js | 4 ++-- packages/mongo/package.js | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/mongo/asynchronous_cursor.js b/packages/mongo/asynchronous_cursor.js index d18dba5faf..355a096ecf 100644 --- a/packages/mongo/asynchronous_cursor.js +++ b/packages/mongo/asynchronous_cursor.js @@ -52,7 +52,7 @@ export class AsynchronousCursor { if (!doc) return null; doc = replaceTypes(doc, replaceMongoAtomWithMeteor); - if (!this._cursorDescription.options.tailable && _.has(doc, '_id')) { + if (!this._cursorDescription.options.tailable && '_id' in doc) { // Did Mongo give us duplicate documents in the same cursor? If so, // ignore this one. (Do this before the transform, since transform might // return some unrelated value.) We don't do this for tailable cursors, @@ -127,7 +127,7 @@ export class AsynchronousCursor { } fetch() { - return this.map(_.identity); + return this.map(doc => doc); } /** diff --git a/packages/mongo/package.js b/packages/mongo/package.js index 43a4d6f816..d6f813024b 100644 --- a/packages/mongo/package.js +++ b/packages/mongo/package.js @@ -19,7 +19,6 @@ Npm.depends({ "lodash.has": "4.5.2", "lodash.throttle": "4.1.1", "lodash.once": "4.1.1", - "lodash.identity": "3.0.0", "lodash.isobject": "3.0.2", "lodash.clone": "4.5.0" });