mirror of
https://github.com/danbulant/discord.js
synced 2026-07-08 12:40:50 +00:00
Fix check for GuildChannel#deletable (#1925)
You can now delete any channel you want, even if its ID is the same as the guild ID
This commit is contained in:
parent
fc1e78e545
commit
3767b35189
1 changed files with 1 additions and 2 deletions
|
|
@ -388,8 +388,7 @@ class GuildChannel extends Channel {
|
||||||
* @readonly
|
* @readonly
|
||||||
*/
|
*/
|
||||||
get deletable() {
|
get deletable() {
|
||||||
return this.id !== this.guild.id &&
|
return this.permissionsFor(this.client.user).has(Permissions.FLAGS.MANAGE_CHANNELS);
|
||||||
this.permissionsFor(this.client.user).has(Permissions.FLAGS.MANAGE_CHANNELS);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue