mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-26 14:19:11 +02:00
Public :)
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
const Command = require('../../structures/Command');
|
||||
const { MessageEmbed, version: djsVersion, Permissions } = require('discord.js');
|
||||
const { MessageEmbed, version: djsVersion } = require('discord.js');
|
||||
const { version: commandoVersion } = require('discord.js-commando');
|
||||
const moment = require('moment');
|
||||
require('moment-duration-format');
|
||||
const { formatNumber } = require('../../util/Util');
|
||||
const { version, dependencies } = require('../../package');
|
||||
const permissions = require('../../assets/json/permissions');
|
||||
const { XIAO_GITHUB_REPO_USERNAME, XIAO_GITHUB_REPO_NAME } = process.env;
|
||||
const source = XIAO_GITHUB_REPO_NAME && XIAO_GITHUB_REPO_USERNAME;
|
||||
|
||||
@@ -22,7 +23,7 @@ module.exports = class InfoCommand extends Command {
|
||||
}
|
||||
|
||||
async run(msg) {
|
||||
const invite = await this.client.generateInvite(Permissions.ALL);
|
||||
const invite = await this.client.generateInvite(permissions);
|
||||
const embed = new MessageEmbed()
|
||||
.setColor(0x00AE86)
|
||||
.setFooter('©2017-2020 dragonfire535#8081')
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
const Command = require('../../structures/Command');
|
||||
const { stripIndents } = require('common-tags');
|
||||
const { XIAO_GITHUB_REPO_NAME, XIAO_GITHUB_REPO_USERNAME } = process.env;
|
||||
const permissions = require('../../assets/json/permissions');
|
||||
|
||||
module.exports = class InviteCommand extends Command {
|
||||
constructor(client) {
|
||||
@@ -14,13 +14,14 @@ module.exports = class InviteCommand extends Command {
|
||||
});
|
||||
}
|
||||
|
||||
run(msg) {
|
||||
async run(msg) {
|
||||
const invite = await this.client.generateInvite(permissions);
|
||||
return msg.say(stripIndents`
|
||||
You cannot invite me to your server, but you can join my home server to use me:
|
||||
${this.client.options.invite || 'Coming soon...'}
|
||||
Invite me using this link:
|
||||
<${invite}>
|
||||
|
||||
You can also self-host me if you prefer:
|
||||
<https://github.com/${XIAO_GITHUB_REPO_USERNAME}/${XIAO_GITHUB_REPO_NAME}>
|
||||
Join my home server for support and announcements:
|
||||
${this.client.options.invite || 'Coming soon...'}
|
||||
`);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user