fix: Closes #3011 guide fixes

This commit is contained in:
Skillz
2023-05-08 13:36:33 -05:00
parent 5edfbb7efb
commit a1b2b3fb2c
3 changed files with 6 additions and 5 deletions
+1 -1
View File
@@ -114,7 +114,7 @@ try {
// OPTIONAL: Runs the raw event handler if you need it
bot.events.raw(bot, req.body.payload, req.body.shardId);
// Runs the event handler if available
if (message.t) bot.events.[snakeToCamelCase(message.t)]?.(req.body.payload, req.body.shardId);
if (message.t) bot.events.[snakeToCamelCase(message.t.toLowerCase())]?.(req.body.payload, req.body.shardId);
res.status(200).json({ success: true })
}