generated from nhcarrigan/template
chore: disable message create event handler
This commit is contained in:
+16
-11
@@ -7,12 +7,15 @@
|
|||||||
import { DiscordAnalytics } from "@nhcarrigan/discord-analytics";
|
import { DiscordAnalytics } from "@nhcarrigan/discord-analytics";
|
||||||
import { Client, Events, GatewayIntentBits, Partials } from "discord.js";
|
import { Client, Events, GatewayIntentBits, Partials } from "discord.js";
|
||||||
import { chatInputInteractionCreate } from "./events/interactionCreate.js";
|
import { chatInputInteractionCreate } from "./events/interactionCreate.js";
|
||||||
import {
|
|
||||||
guildMessageCreate,
|
|
||||||
directMessageCreate,
|
|
||||||
} from "./events/messageCreate.js";
|
|
||||||
import { logger } from "./utils/logger.js";
|
import { logger } from "./utils/logger.js";
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Import {
|
||||||
|
* guildMessageCreate,
|
||||||
|
* directMessageCreate,
|
||||||
|
* } from "./events/messageCreate.js";
|
||||||
|
*/
|
||||||
|
|
||||||
const hikari = new Client({
|
const hikari = new Client({
|
||||||
intents: [
|
intents: [
|
||||||
GatewayIntentBits.Guilds,
|
GatewayIntentBits.Guilds,
|
||||||
@@ -35,13 +38,15 @@ hikari.once(Events.ClientReady, () => {
|
|||||||
analytics.startCron();
|
analytics.startCron();
|
||||||
});
|
});
|
||||||
|
|
||||||
hikari.on(Events.MessageCreate, (message) => {
|
/*
|
||||||
if (!message.inGuild()) {
|
* Hikari.on(Events.MessageCreate, (message) => {
|
||||||
void directMessageCreate(hikari, message);
|
* if (!message.inGuild()) {
|
||||||
return;
|
* void directMessageCreate(hikari, message);
|
||||||
}
|
* return;
|
||||||
void guildMessageCreate(hikari, message);
|
* }
|
||||||
});
|
* void guildMessageCreate(hikari, message);
|
||||||
|
* });
|
||||||
|
*/
|
||||||
|
|
||||||
hikari.on(Events.InteractionCreate, (interaction) => {
|
hikari.on(Events.InteractionCreate, (interaction) => {
|
||||||
if (interaction.isChatInputCommand()) {
|
if (interaction.isChatInputCommand()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user