WIP: [#1]: Athena Rewrite #1
+14
@@ -3,6 +3,8 @@ import { CommandClient, Constants, LRUCollection, Member, User } from "athena-pr
|
||||
|
||||
// Internal Imports
|
||||
import config from "./config";
|
||||
import events from "./events";
|
||||
import commands from "./commands";
|
||||
|
||||
// ---------------
|
||||
|
||||
@@ -21,12 +23,24 @@ const client = new CommandClient({
|
||||
|
||||
largeBotOptimizations: true,
|
||||
|
||||
disableEvents: {
|
||||
PRESENCE_UPDATE: true,
|
||||
},
|
||||
|
||||
// TODO: Move caching to Redis.
|
||||
cache: {
|
||||
users: () => new LRUCollection(User, 1024),
|
||||
members: (guild) => new LRUCollection(Member, 1024),
|
||||
|
||||
guildEmojis: false,
|
||||
guildStickers: false,
|
||||
transientMembers: false,
|
||||
userSweepIntervalMs: 3_600_000 // 1hr.
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
commands.forEach(command => client.registerCommand(command));
|
||||
events.forEach(event => client.registerEvent(event));
|
||||
|
||||
export default client;
|
||||
@@ -0,0 +1,22 @@
|
||||
import database from "./admin/database";
|
||||
import renameChannel from "./admin/rename-channel";
|
||||
|
||||
import ban from "./moderation/ban";
|
||||
import hardban from "./moderation/hardban";
|
||||
|
||||
import about from "./utilities/about";
|
||||
import nameSync from "./utilities/name-sync";
|
||||
|
||||
export default [
|
||||
// Admin
|
||||
database,
|
||||
renameChannel,
|
||||
|
||||
// Moderation
|
||||
ban,
|
||||
hardban,
|
||||
|
||||
// Utilities
|
||||
about,
|
||||
nameSync
|
||||
];
|
||||
Reference in New Issue
Block a user