From 3ec08d5976b7b1cbe4d3aab950e21da56883b16c Mon Sep 17 00:00:00 2001 From: Gus Caplan Date: Mon, 29 May 2017 16:53:49 -0500 Subject: [PATCH] add nsfw options to 11.1 search (#1540) * Update RESTMethods.js * Update TextBasedChannel.js --- src/client/rest/RESTMethods.js | 1 + src/structures/interfaces/TextBasedChannel.js | 1 + 2 files changed, 2 insertions(+) diff --git a/src/client/rest/RESTMethods.js b/src/client/rest/RESTMethods.js index 30d5f4ff9..641468031 100644 --- a/src/client/rest/RESTMethods.js +++ b/src/client/rest/RESTMethods.js @@ -227,6 +227,7 @@ class RESTMethods { embed_type: options.embedType, attachment_filename: options.attachmentFilename, attachment_extension: options.attachmentExtension, + include_nsfw: options.nsfw, }; for (const key in options) if (options[key] === undefined) delete options[key]; diff --git a/src/structures/interfaces/TextBasedChannel.js b/src/structures/interfaces/TextBasedChannel.js index 8fb7995ec..fc70f942f 100644 --- a/src/structures/interfaces/TextBasedChannel.js +++ b/src/structures/interfaces/TextBasedChannel.js @@ -214,6 +214,7 @@ class TextBasedChannel { * @property {Date} [before] Date to find messages before * @property {Date} [after] Date to find messages before * @property {Date} [during] Date to find messages during (range of date to date + 24 hours) + * @property {boolean} [nsfw=false] Include results from NSFW channels */ /**