From 7613abd242e603ecd96e063f8d0044e951252654 Mon Sep 17 00:00:00 2001 From: Caleb Fontenot Date: Sat, 1 Apr 2023 15:37:35 -0500 Subject: [PATCH] More debugging --- abbreviation_key.json | 2 +- main.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/abbreviation_key.json b/abbreviation_key.json index ee4829d..cd971cd 100644 --- a/abbreviation_key.json +++ b/abbreviation_key.json @@ -1 +1 @@ -{"target_phrases":{"idk":"I don't know","hoco":"homecoming","bbl":"be back later","bbg":"baby girl","mb":"my bad","mfw":"my face when","tfw":"that face when","ebr":"East Baton Rouge","ttyl":"talk to you later","ab":"about","abt":"about","dk":"don't know","prolly":"probably","tbh":"to be honest","smh":"shaking my head","btw":"by the way","ngl":"not gonna lie","fr":"for real","yessss":"yes","bc":"because","u":"you","thru":"through","lmao":"laughing my ass off","tldr":"too long; didn't read","ofc":"of course","linux":"GNU/Linux","xfl":"Extreme Football League","bi":"bisexual","abbr":"abbreviation","jk":"just kidding","gm":"good morning","mc":"Minecraft","nfl":"National Football League","ygd":"you're gonna die","gn":"goodnight","gac":"Great American Cookie"}} \ No newline at end of file +{"target_phrases":{"idk":"I don't know","hoco":"homecoming","bbl":"be back later","bbg":"baby girl","mb":"my bad","mfw":"my face when","tfw":"that face when","ebr":"East Baton Rouge","ttyl":"talk to you later","ab":"about","abt":"about","dk":"don't know","prolly":"probably","tbh":"to be honest","smh":"shaking my head","btw":"by the way","ngl":"not gonna lie","fr":"for real","yessss":"yes","bc":"because","u":"you","thru":"through","lmao":"laughing my ass off","tldr":"too long; didn't read","ofc":"of course","linux":"GNU/Linux","xfl":"Extreme Football League","bi":"bisexual","abbr":"abbreviation","jk":"just kidding","gm":"good morning","mc":"Minecraft","nfl":"National Football League","ygd":"you're gonna die","gn":"goodnight","gac":"Great American Cookie","ncaa":"National Collegiate Athletic Association","em":"them","tbf":"to be fair","ppl":"people","bb":"baby","stfu":"shut the frick up","nvm":"nevermind","idc":"I don't care","dc":"don't care","ty":"thank you","yw":"you're welcome"}} \ No newline at end of file diff --git a/main.ts b/main.ts index 96cb363..c5d7d57 100644 --- a/main.ts +++ b/main.ts @@ -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;