dev override

This commit is contained in:
Erik 2022-04-27 20:06:35 +03:00
parent 2cedc24e4e
commit 5443ed294c
Signed by untrusted user: Navy.gif
GPG Key ID: 811EC0CD80E7E5FB

View File

@ -17,8 +17,12 @@ class Permissions extends Inhibitor {
async execute(invoker, command, override = null) {
const userWrapper = await invoker.userWrapper();
if (userWrapper.developer) return super._succeed();
const { guild, member } = invoker;
const { permissions: { type } } = await guild.settings();
const permissions = override ?? command.memberPermissions;
const memberPerms = invoker.channel.permissionsFor(member);