mirror of
https://github.com/discordeno/discordeno.git
synced 2026-09-17 08:47:22 +00:00
Fix conflict
This commit is contained in:
+14
-2
@@ -125,9 +125,11 @@ import {
|
||||
handleIntegrationCreate,
|
||||
handleIntegrationUpdate,
|
||||
handleIntegrationDelete,
|
||||
handleGuildLoaded
|
||||
} from "./handlers/mod.ts";
|
||||
import { DiscordenoInteraction, transformInteraction } from "./transformers/interaction.ts";
|
||||
import { DiscordenoIntegration, transformIntegration } from "./transformers/integration.ts";
|
||||
import {Emoji} from "./types/emojis/emoji.ts";
|
||||
import {handleGuildLoaded} from "./handlers/guilds/GUILD_LOADED_DD.ts";
|
||||
|
||||
export async function createBot(options: CreateBotOptions) {
|
||||
return {
|
||||
@@ -239,6 +241,10 @@ export function createEventHandlers(events: Partial<EventHandlers>): EventHandle
|
||||
channelCreate: events.channelCreate ?? ignore,
|
||||
debug: events.debug ?? ignore,
|
||||
dispatchRequirements: events.dispatchRequirements ?? ignore,
|
||||
integrationCreate: events.integrationCreate ?? ignore,
|
||||
integrationDelete: events.integrationDelete ?? ignore,
|
||||
interactionCreate: events.interactionCreate ?? ignore,
|
||||
channelCreate: events.channelCreate ?? ignore,
|
||||
voiceChannelLeave: events.voiceChannelLeave ?? ignore,
|
||||
channelDelete: events.channelDelete ?? ignore,
|
||||
channelPinsUpdate: events.channelPinsUpdate ?? ignore,
|
||||
@@ -485,6 +491,8 @@ export interface Transformers {
|
||||
message: typeof transformMessage;
|
||||
role: typeof transformRole;
|
||||
voiceState: typeof transformVoiceState;
|
||||
interaction: typeof transformInteraction;
|
||||
integration: typeof transformIntegration;
|
||||
}
|
||||
|
||||
export function createTransformers(options: Partial<Transformers>) {
|
||||
@@ -497,6 +505,7 @@ export function createTransformers(options: Partial<Transformers>) {
|
||||
message: options.message || transformMessage,
|
||||
role: options.role || transformRole,
|
||||
voiceState: options.voiceState || transformVoiceState,
|
||||
integration: options.integration || transformIntegration,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -606,6 +615,10 @@ export interface GatewayManager {
|
||||
|
||||
export interface EventHandlers {
|
||||
debug: (text: string) => unknown;
|
||||
interactionCreate: (bot: Bot, interaction: DiscordenoInteraction) => any;
|
||||
integrationCreate: (bot: Bot, integration: DiscordenoIntegration) => any;
|
||||
integrationDelete: (bot: Bot, payload: { id: bigint; guildId: bigint; applicationId?: bigint }) => any;
|
||||
integrationsUpdate: (bot: Bot, integration: DiscordenoIntegration) => any;
|
||||
channelCreate: (bot: Bot, channel: DiscordenoChannel) => any;
|
||||
dispatchRequirements: (bot: Bot, data: GatewayPayload, shardId: number) => any;
|
||||
voiceChannelLeave: (bot: Bot, voiceState: DiscordenoVoiceState, channel: DiscordenoChannel) => any;
|
||||
@@ -658,7 +671,6 @@ export interface EventHandlers {
|
||||
guildCreate: (bot: Bot, guild: DiscordenoGuild) => any;
|
||||
guildDelete: (bot: Bot, id: bigint, guild?: DiscordenoGuild) => any;
|
||||
guildUpdate: (bot: Bot, guild: DiscordenoGuild, cachedGuild?: DiscordenoGuild) => any;
|
||||
integrationsUpdate: (bot: Bot, data: { guildId: bigint }) => any;
|
||||
raw: (bot: Bot, data: GatewayPayload, shardId: number) => any;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user