mirror of
https://github.com/danbulant/discord.js
synced 2026-05-24 12:35:53 +00:00
Fix for a small hasPermission error (#1971)
This commit is contained in:
parent
f89ec00b30
commit
82841c6ce1
1 changed files with 1 additions and 1 deletions
|
|
@ -306,7 +306,7 @@ class GuildMember extends Base {
|
|||
if (typeof checkAdmin === 'undefined') checkAdmin = !explicit;
|
||||
if (typeof checkOwner === 'undefined') checkOwner = !explicit;
|
||||
if (checkOwner && this.user.id === this.guild.ownerID) return true;
|
||||
return this.roles.some(r => r.hasPermission(permission, undefined, checkAdmin));
|
||||
return this.roles.some(r => r.permissions.has(permission, undefined, checkAdmin));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue