Skip to content

Commit

Permalink
convert buttonHandler
Browse files Browse the repository at this point in the history
  • Loading branch information
alexemanuelol committed Aug 4, 2024
1 parent 1ecf7ae commit 293cd90
Show file tree
Hide file tree
Showing 2 changed files with 151 additions and 119 deletions.
3 changes: 2 additions & 1 deletion src/discordEvents/interactionCreate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import * as discordEmbeds from '../discordTools/discord-embeds';
import * as discordTools from '../discordTools/discord-tools';
import { selectMenuHandler } from '../handlers/select-menu-handler';
import { modalHandler } from '../handlers/modal-handler';
import { buttonHandler } from '../handlers/button-handler';
const Config = require('../../config');


Expand All @@ -49,7 +50,7 @@ export async function execute(interaction: Interaction) {
}

if (interaction.isButton()) {
require('../handlers/buttonHandler')(client, interaction); //! TODO Needs to be refactored for typescript
await buttonHandler(interaction);
}
else if (interaction.isStringSelectMenu()) {
await selectMenuHandler(interaction);
Expand Down
Loading

0 comments on commit 293cd90

Please sign in to comment.