RIP Database again

This commit is contained in:
Daniel Odendahl Jr
2017-10-01 22:50:28 +00:00
parent 2068122e11
commit 4f5c6bd643
5 changed files with 7 additions and 290 deletions
+5 -7
View File
@@ -1,7 +1,7 @@
const { TOKEN, OWNERS, COMMAND_PREFIX, INVITE } = process.env;
const path = require('path');
const Client = require('./structures/Client');
const client = new Client({
const { CommandoClient } = require('discord.js-commando');
const client = new CommandoClient({
commandPrefix: COMMAND_PREFIX,
owner: OWNERS.split(','),
invite: INVITE,
@@ -11,14 +11,12 @@ const client = new Client({
messageCacheLifetime: 600,
messageSweepInterval: 120
});
const SequelizeProvider = require('./providers/Sequelize');
const { postStats } = require('./structures/Util');
client.registry
.registerDefaultTypes()
.registerGroups([
['util', 'Utility'],
['commands', 'Command Management'],
['user-info', 'User Info'],
['guild-info', 'Server Info'],
['moderation', 'Moderation'],
@@ -35,12 +33,12 @@ client.registry
])
.registerDefaultCommands({
help: false,
ping: false
ping: false,
prefix: false,
commandState: false
})
.registerCommandsIn(path.join(__dirname, 'commands'));
client.setProvider(new SequelizeProvider(client.database));
client.on('ready', () => {
console.log(`[READY] Shard ${client.shard.id} logged in as ${client.user.tag} (${client.user.id})!`);
client.setInterval(() => {