From df7616aa6ef55115a2399ce6dcc0914d3246ace7 Mon Sep 17 00:00:00 2001 From: ckohen Date: Mon, 3 Jan 2022 00:11:54 -0800 Subject: [PATCH] fix(sweepers): provide default for object param --- packages/discord.js/src/util/Sweepers.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/discord.js/src/util/Sweepers.js b/packages/discord.js/src/util/Sweepers.js index 7703416c7e60..ab91bf958833 100644 --- a/packages/discord.js/src/util/Sweepers.js +++ b/packages/discord.js/src/util/Sweepers.js @@ -375,11 +375,11 @@ class Sweepers { * Sweep a direct sub property of all guilds * @param {string} key The name of the property * @param {Function} filter Filter function passed to sweep - * @param {SweepEventOptions} [eventOptions] Options for the Client event emitted here + * @param {SweepEventOptions} [eventOptions={}] Options for the Client event emitted here * @returns {Object} Object containing the number of guilds swept and the number of items swept * @private */ - _sweepGuildDirectProp(key, filter, { emit = true, outputName }) { + _sweepGuildDirectProp(key, filter, { emit = true, outputName } = {}) { if (typeof filter !== 'function') { throw new TypeError('INVALID_TYPE', 'filter', 'function'); }