Skip to content

Commit

Permalink
fix(DiscordBot): Pass event args without modifications
Browse files Browse the repository at this point in the history
Events were getting args that are after bot as an array, now they're being passed as separate args
  • Loading branch information
The Alpha committed Jan 7, 2024
1 parent a5f729a commit 69e0832
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/class/discordBot.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ class DiscordBot extends Client {
const e = event
const { data, execute } = e
/** @type {import('../options').ClientEventFunction<any>} */
const func = (...args) => execute(this, [...args])
const func = (args) => execute(this, args)

if (data.name === Events.ClientReady || data.once) {
this.once(data.name, func)
Expand Down

0 comments on commit 69e0832

Please sign in to comment.