forked from Supositware/Haha-Yes
Fixed error on guilds
This commit is contained in:
parent
60065159e5
commit
706867ae53
1 changed files with 5 additions and 2 deletions
|
@ -45,8 +45,11 @@ class userBlacklistCommand extends Command {
|
||||||
if (!blacklist) {
|
if (!blacklist) {
|
||||||
const body = {type:args.command, uid: args.userID, reason: args.reason};
|
const body = {type:args.command, uid: args.userID, reason: args.reason};
|
||||||
Blacklists.create(body);
|
Blacklists.create(body);
|
||||||
let user = this.client.users.resolve(args.userID);
|
let user = args.userID;
|
||||||
return message.channel.send(`${user.tag} has been blacklisted from ${args.command} with the following reason ${args.reason}`);
|
if (args.command !== 'guild')
|
||||||
|
user = this.client.users.resolve(args.userID).tag;
|
||||||
|
|
||||||
|
return message.channel.send(`${user} has been blacklisted from ${args.command} with the following reason ${args.reason}`);
|
||||||
} else {
|
} else {
|
||||||
message.channel.send('This user is already blacklisted, do you want to unblacklist him? y/n');
|
message.channel.send('This user is already blacklisted, do you want to unblacklist him? y/n');
|
||||||
const filter = m => m.content && m.author.id === message.author.id;
|
const filter = m => m.content && m.author.id === message.author.id;
|
||||||
|
|
Loading…
Reference in a new issue