More debugging

This commit is contained in:
2023-04-01 15:37:35 -05:00
parent e899695f74
commit 7613abd242
2 changed files with 3 additions and 2 deletions

View File

@@ -125,12 +125,13 @@ client.on('messageCreate', message => {
//Return key
var phrase = abbreviationKey.target_phrases[matchMessageArray[i]];
var abbr = matchAbbr(phrase); //abbreviationKey.target_phrases[phrase];
console.log(typeof(abbr));
//console.log(typeof(abbr));
console.log("Found abbreviation: " + abbr);
console.log("Phrase that matches used acronym: " + phrase);
if (abbr !== "") {
rebuildMessageArray = correctedMessage.split(new RegExp(abbr, 'i'));
console.log("rebuildMessageArray: " + rebuildMessageArray);
} else {
message.reply("Detected abbreviation, but regex matching broke. Caleb is working on this...");
break;