discordx-ts / discordx

🤖 Create a discord bot with TypeScript and Decorators!
https://discordx.js.org
Apache License 2.0
621 stars 50 forks source link

[Bug]: interaction type guards out of date. #774

Closed CoreParadox closed 2 years ago

CoreParadox commented 2 years ago

What happened?

According to: https://github.com/discordjs/discord.js/issues/8072#issuecomment-1153015242 Some checks should be replaced with interaction.type == InteractionType.[Type]

There is some desync between the dev branches of discordx and discord.js related to this issue.

Reproduction

Try to use a modal submit action

Package

discordx

Version

Dev

Relevant log output

interaction.isModalSubmit is not a function

TypeError: interaction.isModalSubmit is not a function
    at Bot.executeInteraction 
    (F:\\Dev\\Node.js\\TypescriptBot\\node_modules\\discordx\\src\\Client.ts:1227:19)

...

Code of Conduct

vijayymmeena commented 2 years ago

Hi, thanks for reporting. I see the permissions PR is merged as well. Which, we have not yet worked on. until we do, you can downgrade your djs dev version to last supported version, see package.json of discordx for that. Will try to sync as soon as possible,

vijayymmeena commented 2 years ago

Hi, sorry for the delay. dev branch now synchronized