From 78c4be52c60ea6fa2bb3b34d28562078e0b32082 Mon Sep 17 00:00:00 2001 From: Souji Date: Wed, 10 Oct 2018 10:29:53 +0200 Subject: [PATCH] docs(Collection): clarify example for tap method (#2881) * docs: clarify example for Collection#tap * docs: wording improvement --- src/util/Collection.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/util/Collection.js b/src/util/Collection.js index 887d999b1..7f0570d6c 100644 --- a/src/util/Collection.js +++ b/src/util/Collection.js @@ -349,9 +349,9 @@ class Collection extends Map { * @returns {Collection} * @example * collection - * .tap(coll => coll.size) + * .tap(coll => console.log(`${coll.size} users, including bots`)) * .filter(user => user.bot) - * .tap(coll => coll.size) + * .tap(coll => console.log(`${coll.size} users, excluding bots`)) */ tap(fn, thisArg) { if (typeof thisArg !== 'undefined') fn = fn.bind(thisArg);