feat(Guild): nsfw guilds (#5525)

Co-authored-by: Advaith <advaithj1@gmail.com>
This commit is contained in:
Souji
2021-04-18 18:52:53 +02:00
committed by GitHub
parent 1be67b8851
commit 596832371c
2 changed files with 9 additions and 0 deletions

View File

@@ -101,6 +101,14 @@ class Guild extends Base {
* @type {number}
*/
this.shardID = data.shardID;
if ('nsfw' in data) {
/**
* Whether the guild is designated as not safe for work
* @type {boolean}
*/
this.nsfw = data.nsfw;
}
}
/**

1
typings/index.d.ts vendored
View File

@@ -641,6 +641,7 @@ declare module 'discord.js' {
public mfaLevel: number;
public name: string;
public readonly nameAcronym: string;
public nsfw: boolean;
public ownerID: Snowflake;
public readonly partnered: boolean;
public preferredLocale: string;