mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 00:23:30 +01:00
Docs for permissionoverwrites
This commit is contained in:
@@ -1,5 +1,12 @@
|
||||
/**
|
||||
* Represents a permission overwrite for a Role or Member in a Guild Channel.
|
||||
*/
|
||||
class PermissionOverwrites {
|
||||
constructor(guildChannel, data) {
|
||||
/**
|
||||
* The GuildChannel this overwrite is for
|
||||
* @type {GuildChannel}
|
||||
*/
|
||||
this.channel = guildChannel;
|
||||
if (data) {
|
||||
this.setup(data);
|
||||
@@ -7,7 +14,15 @@ class PermissionOverwrites {
|
||||
}
|
||||
|
||||
setup(data) {
|
||||
/**
|
||||
* The type of this overwrite
|
||||
* @type {String}
|
||||
*/
|
||||
this.type = data.type;
|
||||
/**
|
||||
* The ID of this overwrite, either a User ID or a Role ID
|
||||
* @type {String}
|
||||
*/
|
||||
this.id = data.id;
|
||||
this.denyData = data.deny;
|
||||
this.allowData = data.allow;
|
||||
|
||||
Reference in New Issue
Block a user