🧑💻 Fixed some code smells
This commit is contained in:
parent
229ee5c97b
commit
3333063a47
1 changed files with 3 additions and 2 deletions
|
@ -1,5 +1,6 @@
|
||||||
import {
|
import {
|
||||||
BaseInteraction,
|
BaseInteraction,
|
||||||
|
ButtonInteraction,
|
||||||
ChatInputCommandInteraction,
|
ChatInputCommandInteraction,
|
||||||
CommandInteraction,
|
CommandInteraction,
|
||||||
EmbedBuilder,
|
EmbedBuilder,
|
||||||
|
@ -10,7 +11,7 @@ import button from "./button";
|
||||||
import command from "./command";
|
import command from "./command";
|
||||||
|
|
||||||
export const execute = async (interaction: BaseInteraction) => {
|
export const execute = async (interaction: BaseInteraction) => {
|
||||||
await button(interaction);
|
await button(<ButtonInteraction>interaction);
|
||||||
await command(<ChatInputCommandInteraction>interaction);
|
await command(<ChatInputCommandInteraction>interaction);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -21,7 +22,7 @@ export const handleCommandInteraction = async (
|
||||||
interaction.guild
|
interaction.guild
|
||||||
);
|
);
|
||||||
|
|
||||||
await command(<ChatInputCommandInteraction>interaction).catch(async (err) => {
|
await command(<ChatInputCommandInteraction>interaction).catch((err) => {
|
||||||
return interaction.editReply({
|
return interaction.editReply({
|
||||||
embeds: [
|
embeds: [
|
||||||
new EmbedBuilder()
|
new EmbedBuilder()
|
||||||
|
|
Loading…
Add table
Reference in a new issue