feat: Add rtcRegion to GuildManager#create() (#6858)

This commit is contained in:
Jiralite
2021-10-19 15:11:29 +01:00
committed by GitHub
parent e0afcadda4
commit 399e720b92
2 changed files with 5 additions and 0 deletions

View File

@@ -91,6 +91,7 @@ class GuildManager extends CachedManager {
* @property {boolean} [nsfw] Whether the channel is NSFW
* @property {number} [bitrate] The bitrate of the voice channel
* @property {number} [userLimit] The user limit of the channel
* @property {?string} [rtcRegion] The RTC region of the channel
* @property {PartialOverwriteData[]} [permissionOverwrites]
* Overwrites of the channel
* @property {number} [rateLimitPerUser] The rate limit per user (slowmode) of the channel in seconds
@@ -196,6 +197,9 @@ class GuildManager extends CachedManager {
delete channel.userLimit;
channel.rate_limit_per_user = channel.rateLimitPerUser;
delete channel.rateLimitPerUser;
channel.rtc_region = channel.rtcRegion;
delete channel.rtcRegion;
if (!channel.permissionOverwrites) continue;
for (const overwrite of channel.permissionOverwrites) {
if (typeof overwrite.type === 'string') {

1
typings/index.d.ts vendored
View File

@@ -4708,6 +4708,7 @@ export interface PartialChannelData {
nsfw?: boolean;
bitrate?: number;
userLimit?: number;
rtcRegion?: string | null;
permissionOverwrites?: PartialOverwriteData[];
rateLimitPerUser?: number;
}