please
parent
301f9ff9a2
commit
2274959f8a
|
@ -24,11 +24,13 @@ export default class {
|
|||
hasUserPerms = resolved.permissions.users.includes(message.author.id);
|
||||
}
|
||||
let hasRolePerms: boolean = false;
|
||||
if (resolved.permissions.roles) {
|
||||
for (const role of resolved.permissions.roles) {
|
||||
if (message.member && message.member.roles.includes(role)) {
|
||||
hasRolePerms = true; break;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!hasRolePerms && !hasUserPerms) return;
|
||||
if (!resolved.enabled) { message.channel.createMessage(`***${this.client.stores.emojis.error} This command has been disabled***`); return; }
|
||||
const args: string[] = noPrefix.slice(1);
|
||||
|
|
Loading…
Reference in New Issue