forked from Supositware/Haha-Yes
fix blocking multiple commands
This commit is contained in:
parent
a617abea3a
commit
1386bf31ca
1 changed files with 1 additions and 1 deletions
|
@ -30,7 +30,7 @@ class commandblockCommand extends Command {
|
||||||
async exec(message, args) {
|
async exec(message, args) {
|
||||||
if (args.command.id == 'commandblock') return message.channel.send('Whoa there, i can\'t let you block this command or else how would you unblock it?');
|
if (args.command.id == 'commandblock') return message.channel.send('Whoa there, i can\'t let you block this command or else how would you unblock it?');
|
||||||
|
|
||||||
const blocked = await commandblock.findOne({where: {serverID: message.guild.id}});
|
const blocked = await commandblock.findOne({where: {serverID: message.guild.id, command: args.command.id}});
|
||||||
|
|
||||||
if (!blocked) {
|
if (!blocked) {
|
||||||
const body = {serverID: message.guild.id, command: args.command.id};
|
const body = {serverID: message.guild.id, command: args.command.id};
|
||||||
|
|
Loading…
Reference in a new issue