diff --git a/config.example.ts b/config.example.ts index d7a301c..7d21b05 100644 --- a/config.example.ts +++ b/config.example.ts @@ -1,6 +1,6 @@ export const config = { 'name': 'Sweeper Bot', // Name of the bot - 'version': '0.2.0', // Version of the bot + 'version': '0.2.1', // Version of the bot 'token': 'the_bot_token', // Discord API Token for this bot 'localtoken': 'local_testing_token', // Discord API Token for a secondary OPTIONAL testing bot, THIS MUST BE DIFFERENT FROM "token" 'prefix': 's!', // Prefix for all commands diff --git a/src/commands/handleMentions.ts b/src/commands/handleMentions.ts index 61ea58e..e1171ed 100644 --- a/src/commands/handleMentions.ts +++ b/src/commands/handleMentions.ts @@ -14,9 +14,6 @@ import utils from '../utils.ts'; export const handleMentions = (bot: Bot, message: Message) => { log(LT.LOG, `Handling @mention message: ${utils.jsonStringifyBig(message)}`); - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('mention')).catch((e) => utils.commonLoggers.dbError('handleMentions.ts:17', 'call sproc INC_CNT on', e)); - bot.helpers.sendMessage(message.channelId, { embeds: [{ color: infoColor1, diff --git a/src/commands/help.ts b/src/commands/help.ts index 04bd3c1..01eb30d 100644 --- a/src/commands/help.ts +++ b/src/commands/help.ts @@ -9,9 +9,6 @@ import { infoColor2 } from '../commandUtils.ts'; import utils from '../utils.ts'; export const help = (bot: Bot, message: Message) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('help')).catch((e) => utils.commonLoggers.dbError('htlp.ts:15', 'call sproc INC_CNT on', e)); - bot.helpers.sendMessage(message.channelId, { embeds: [{ color: infoColor2, diff --git a/src/commands/info.ts b/src/commands/info.ts index 4c760ea..8e5f437 100644 --- a/src/commands/info.ts +++ b/src/commands/info.ts @@ -9,9 +9,6 @@ import { infoColor2 } from '../commandUtils.ts'; import utils from '../utils.ts'; export const info = (bot: Bot, message: Message) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('info')).catch((e) => utils.commonLoggers.dbError('info.ts:12', 'call sproc INC_CNT on', e)); - bot.helpers.sendMessage(message.channelId, { embeds: [{ color: infoColor2, diff --git a/src/commands/ping.ts b/src/commands/ping.ts index e1ced0d..357495b 100644 --- a/src/commands/ping.ts +++ b/src/commands/ping.ts @@ -8,9 +8,6 @@ import { generatePing } from '../commandUtils.ts'; import utils from '../utils.ts'; export const ping = async (bot: Bot, message: Message) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('ping')).catch((e) => utils.commonLoggers.dbError('ping.ts:14', 'call sproc INC_CNT on', e)); - // Calculates ping between sending a message and editing it, giving a nice round-trip latency. try { const m = await bot.helpers.sendMessage(message.channelId, generatePing(-1)); diff --git a/src/commands/report.ts b/src/commands/report.ts index 9ebf0d3..c8ed7bb 100644 --- a/src/commands/report.ts +++ b/src/commands/report.ts @@ -11,9 +11,6 @@ import { failColor, generateReport, successColor } from '../commandUtils.ts'; import utils from '../utils.ts'; export const report = (bot: Bot, message: Message, args: string[]) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('report')).catch((e) => utils.commonLoggers.dbError('report.ts:17', 'call sproc INC_CNT on', e)); - if (args.join(' ')) { sendMessage(bot, config.reportChannel, generateReport(args.join(' '))).catch((e: Error) => utils.commonLoggers.messageSendError('report.ts:22', message, e)); bot.helpers.sendMessage(message.channelId, { diff --git a/src/commands/sendMessage.ts b/src/commands/sendMessage.ts index 32c614e..202f1bd 100644 --- a/src/commands/sendMessage.ts +++ b/src/commands/sendMessage.ts @@ -10,9 +10,6 @@ import { failColor, successColor } from '../commandUtils.ts'; import utils from '../utils.ts'; export const sendMsg = (bot: Bot, message: Message, args: string[]) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('report')).catch((e) => utils.commonLoggers.dbError('report.ts:17', 'call sproc INC_CNT on', e)); - try { const channelId = BigInt(args.shift() || '0'); diff --git a/src/commands/version.ts b/src/commands/version.ts index caa5144..ed9f724 100644 --- a/src/commands/version.ts +++ b/src/commands/version.ts @@ -9,9 +9,6 @@ import { infoColor1 } from '../commandUtils.ts'; import utils from '../utils.ts'; export const version = (bot: Bot, message: Message) => { - // Light telemetry to see how many times a command is being run - // dbClient.execute(queries.callIncCnt('version')).catch((e) => utils.commonLoggers.dbError('version.ts:15', 'call sproc INC_CNT on', e)); - bot.helpers.sendMessage(message.channelId, { embeds: [{ color: infoColor1, diff --git a/src/events/messageUpdate.ts b/src/events/messageUpdate.ts index 3ada013..56441ba 100644 --- a/src/events/messageUpdate.ts +++ b/src/events/messageUpdate.ts @@ -16,8 +16,5 @@ export const messageUpdate = (bot: Bot, message: Message) => { if (config.pollChannels.includes(message.channelId)) { functions.pollReactions(bot, message, true); } - - // return as we are done handling this command - return; } };