Browse Source

Fix catch block to log errors

pull/9/head
Abheek Dhawan 4 years ago
parent
commit
6ad00072ec
  1. 5
      bot/awesomescibo.js

5
bot/awesomescibo.js

@ -280,7 +280,7 @@ async function otherCommands(message) {
); );
} }
}) })
.catch((collected) => {}); // Reaction message filter .catch(console.error); // Reaction message filter
}) })
.catch((collected, error) => { .catch((collected, error) => {
message.reply("\n**ANSWER TIMEOUT**"); message.reply("\n**ANSWER TIMEOUT**");
@ -505,8 +505,11 @@ client.on("message", async (message) => {
return; return;
} }
// Temporary logging purposes
const formattedMessage = message.content.toLowerCase().replace(/ /g, ""); const formattedMessage = message.content.toLowerCase().replace(/ /g, "");
if (formattedMessage.startsWith("dobe")) { if (formattedMessage.startsWith("dobe")) {
console.log(`${message.author.tag} > ${message.content}`);
// Bot prefix is "do be" // Bot prefix is "do be"
switch (formattedMessage) { switch (formattedMessage) {
case "dobehelping": // Display help message case "dobehelping": // Display help message

Loading…
Cancel
Save