Allow to send invite in current channel
This commit is contained in:
parent
c309885d63
commit
08b9f730a3
1 changed files with 15 additions and 3 deletions
|
@ -6,6 +6,13 @@ class InviteCommand extends Command {
|
||||||
super('invite', {
|
super('invite', {
|
||||||
aliases: ['invite'],
|
aliases: ['invite'],
|
||||||
category: 'utility',
|
category: 'utility',
|
||||||
|
args: [
|
||||||
|
{
|
||||||
|
id: 'here',
|
||||||
|
type: 'string',
|
||||||
|
optional: true
|
||||||
|
}
|
||||||
|
],
|
||||||
description: {
|
description: {
|
||||||
content: 'Send invite link for the bot and support server',
|
content: 'Send invite link for the bot and support server',
|
||||||
usage: '',
|
usage: '',
|
||||||
|
@ -14,9 +21,14 @@ class InviteCommand extends Command {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
async exec(message) {
|
async exec(message, args) {
|
||||||
|
let invMessage = `You can add me from here: https://discordapp.com/oauth2/authorize?client_id=${this.client.user.id}&scope=bot&permissions=0\nYou can also join my support server over here: ${supportServer} come and say hi :)`;
|
||||||
|
if (args.here == 'here') {
|
||||||
|
message.channel.send(invMessage);
|
||||||
|
} else {
|
||||||
message.channel.send('Check your dm');
|
message.channel.send('Check your dm');
|
||||||
return message.author.send(`You can add me from here: https://discordapp.com/oauth2/authorize?client_id=${this.client.user.id}&scope=bot&permissions=0\nYou can also join my support server over here: ${supportServer} come and say hi :)`);
|
return message.author.send(invMessage);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue