Satan1c
Satan1c
Explore posts from servers
DIAdiscord.js - Imagine an app
Created by Satan1c on 11/3/2023 in #djs-questions
[Unknown Interaction] from any deferReply, and from some editReply/reply
as an example of usage:
export class MyService {
constructor(@Inject('client') client: Client) {
this.client = client;
this.client.on('interactionCreate', this.onInteraction.bind(this));
}
async onInteraction(interaction: BaseInteraction) {
if (!interaction.isCommand()) return;
await interaction.deferReply({ ephemeral: true });
await this.serviceCommanbds.execute(interaction);
}
}
export class MyService {
constructor(@Inject('client') client: Client) {
this.client = client;
this.client.on('interactionCreate', this.onInteraction.bind(this));
}
async onInteraction(interaction: BaseInteraction) {
if (!interaction.isCommand()) return;
await interaction.deferReply({ ephemeral: true });
await this.serviceCommanbds.execute(interaction);
}
}
no matter where I put deferReply first 3-4 usage of command will trigger error, sometimes on 3+ usages it executes normally bot ping on host->discord 80-100ms, so it mustn't be a "long response"
14 replies