Skip to content

Commit

Permalink
add logs
Browse files Browse the repository at this point in the history
  • Loading branch information
ledouxm committed Mar 4, 2024
1 parent 33964bf commit c6ca219
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/commands/buttons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ export const executeButtonInteraction = async (interaction: ButtonInteraction) =
const { details, participantIndex: pIndex } = game[0];
const index = participantIndex ?? pIndex;

const participant = details.info.participants[index];
console.log({ index, participantIndex, pIndex, id: interaction.customId });
const participant = details.info.participants[Number(index)];

const file = await createMatchDetailsFile(details, participant);

Expand Down Expand Up @@ -56,7 +57,7 @@ export const executeButtonInteraction = async (interaction: ButtonInteraction) =
const { details, participantIndex: pIndex } = game[0];
const index = participantIndex ?? pIndex;

const participant = details.info.participants[index];
const participant = details.info.participants[Number(index)];

const file = await createMatchDamageFile(details, participant);

Expand Down

0 comments on commit c6ca219

Please sign in to comment.