Send unsanitized content to commands via content parameter, fixed emote command, removed another async promise

This commit is contained in:
TheEssem 2021-03-16 13:24:21 -05:00
parent cb8f939378
commit 74baa29684
3 changed files with 10 additions and 11 deletions

View file

@ -70,7 +70,7 @@ module.exports = async (message) => {
try {
await database.addCount(collections.aliases.has(command) ? collections.aliases.get(command) : command);
const startTime = new Date();
const result = await cmd(message, args, content.replace(command, "").trim()); // we also provide the message content as a parameter for cases where we need more accuracy
const result = await cmd(message, args, message.content.substring(prefix.length).trim().replace(command, "").trim()); // we also provide the message content as a parameter for cases where we need more accuracy
const endTime = new Date();
if (typeof result === "string" || (typeof result === "object" && result.embed)) {
await client.createMessage(message.channel.id, result);