From 691aaef07e49a53686ecf13a5ae37d01e1b9460f Mon Sep 17 00:00:00 2001 From: SpaceEEC Date: Sat, 17 Nov 2018 17:24:48 +0100 Subject: [PATCH] backport(Guild): support for rateLimitPerUser when creating a channel PR: #2878 Commit: 8ec3b5134dcd55c5d18910ad0d751ef0c01568d6 --- src/client/rest/RESTMethods.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/client/rest/RESTMethods.js b/src/client/rest/RESTMethods.js index b80b463a7..4b3a7c285 100644 --- a/src/client/rest/RESTMethods.js +++ b/src/client/rest/RESTMethods.js @@ -260,7 +260,8 @@ class RESTMethods { }); } - createChannel(guild, name, { type, topic, nsfw, bitrate, userLimit, parent, permissionOverwrites, reason }) { + createChannel(guild, name, options) { + const { type, topic, nsfw, bitrate, userLimit, parent, permissionOverwrites, rateLimitPerUser, reason } = options; return this.rest.makeRequest('post', Endpoints.Guild(guild).channels, true, { name, topic, @@ -270,6 +271,7 @@ class RESTMethods { user_limit: userLimit, parent_id: parent instanceof Channel ? parent.id : parent, permission_overwrites: resolvePermissions.call(this, permissionOverwrites, guild), + rate_limit_per_user: rateLimitPerUser, }, undefined, reason).then(data => this.client.actions.ChannelCreate.handle(data).channel);