mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-02 17:00:08 +00:00
* Plugins/Permissions: FIX PARITY ISSUES What is parity issues? Parity issues are files that exist but structured one way in the base/vanilla discordeno library, and structured another way in the permisison plugin. * deno fmt * plugins/permissions: nuke validations * plugins/permissions VALIDATIONS -> plugins/validations * plugins/validations: slash commands max 4000 chars * fix module not found
37 lines
1.0 KiB
TypeScript
37 lines
1.0 KiB
TypeScript
import { Bot } from "./deps.ts";
|
|
import { channels } from "./src/channels/mod.ts";
|
|
import { guilds } from "./src/guilds/mod.ts";
|
|
import { interactions } from "./src/interaction/mod.ts";
|
|
import { invites } from "./src/invites/mod.ts";
|
|
import { members } from "./src/members/mod.ts";
|
|
import { messages } from "./src/messages/mod.ts";
|
|
import { misc } from "./src/misc/mod.ts";
|
|
import { webhooks } from "./src/webhooks/mod.ts";
|
|
|
|
// PLUGINS MUST TAKE A BOT ARGUMENT WHICH WILL BE MODIFIED
|
|
export function enableValidationsPlugin(bot: Bot) {
|
|
// MARK THIS PLUGIN BEING USED
|
|
bot.enabledPlugins.add("VALIDATIONS");
|
|
|
|
// BEGIN OVERRIDING HELPER FUNCTIONS
|
|
channels(bot);
|
|
guilds(bot);
|
|
interactions(bot);
|
|
invites(bot);
|
|
members(bot);
|
|
messages(bot);
|
|
misc(bot);
|
|
webhooks(bot);
|
|
|
|
// PLUGINS MUST RETURN THE BOT
|
|
return bot;
|
|
}
|
|
|
|
// EXPORT ALL UTIL FUNCTIONS
|
|
export * from "./src/applicationCommandOptions.ts";
|
|
export * from "./src/attachments.ts";
|
|
export * from "./src/components.ts";
|
|
|
|
// DEFAULT MAKES IT SLIGHTLY EASIER TO USE
|
|
export default enableValidationsPlugin;
|