Files
xiao/commands/util/invite.js
T
Daniel Odendahl Jr c5f29c59c5 Guard All Util Commands
2017-05-28 14:04:48 +00:00

25 lines
745 B
JavaScript

const { Command } = require('discord.js-commando');
const { stripIndents } = require('common-tags');
module.exports = class InviteCommand extends Command {
constructor(client) {
super(client, {
name: 'invite',
group: 'util',
memberName: 'invite',
description: 'Sends you an invite for the bot and an invite to my server.',
guarded: true
});
}
async run(msg) {
const invite = await this.client.generateInvite('1345846343');
return msg.say(stripIndents`
Add me to your server with this link:
<${invite}>
Or, come to my server with this link:
${this.client.options.invite}
`);
}
};