From 1f4b941cdcca34e3cbf4c3eeb14d8090f0f5bbdd Mon Sep 17 00:00:00 2001 From: Dalton Date: Fri, 7 Dec 2018 20:50:40 -0800 Subject: [PATCH] tagged all debugs :) --- bot.js | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/bot.js b/bot.js index 552dc4b..c1681a9 100644 --- a/bot.js +++ b/bot.js @@ -66,7 +66,7 @@ function commandsHelp(requestedCommand) { // For now abstracting this, so we can maybe use config later. // content should be a string or something js thinks is a string :) -function sendToBotTestingChannel(content) { +function sendToBotg(content) { console.log(content); client.channels.get('357365312620068874').send(content); } @@ -170,7 +170,7 @@ function imgurRequest(subreddit, page_max) { } } catch (error) { // Ignore the error and let the calling method handle the empty string. - sendToBotTestingChannel(error.message); + sendToBotTestingChannel('imgur:' + error.message); } } } @@ -221,7 +221,7 @@ function asyncSiteRequest(url, process) { return process(data); }) .catch(error => { - sendToBotTestingChannel(error.message); + sendToBotTestingChannel('async:' + error.message); return ""; }) } @@ -255,7 +255,7 @@ function subredditRequest(subreddit) { { // Ignore the error and continue. // continue; <-- last line in the loop... so does nothing. - sendToBotTestingChannel(error.message); + sendToBotTestingChannel('reddit:' + error.message); } if (counter > 5) { @@ -393,8 +393,7 @@ client.on('ready', () => { // todo this set activity returns a promise and we aren't doing anything with it client.user.setActivity(setStatus, {type: setType}) .catch(error => { - sendToBotTestingChannel(error.message); - console.log(error.message); + sendToBotTestingChannel('client.user.setActivity:' + error.message); }); }) ;