From 0d3935d5c6ced920257a218db7c5b73ce0a942aa Mon Sep 17 00:00:00 2001 From: ION606 Date: Sun, 3 Jul 2022 19:42:37 +0300 Subject: [PATCH] Fixed the problem with using the '\!chat' command --- commands/API/chat.js | 7 +++++-- commands/dm_handler.js | 2 ++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/commands/API/chat.js b/commands/API/chat.js index 6440bb6..e182de1 100644 --- a/commands/API/chat.js +++ b/commands/API/chat.js @@ -57,7 +57,7 @@ async function convoManager(clientinp, bot, message) { dbo.updateOne(doc, {$set: {convo: convo}}); response = response.replaceAll('AI: ', '').replaceAll('AI:\n', ''); - console.log(response); + message.reply(response); }); } @@ -66,5 +66,8 @@ async function convoManager(clientinp, bot, message) { module.exports = { name: 'chat', description: 'chat', - convoManager + convoManager, + execute(message, args, Discord, Client, bot) { + message.reply("Please DM Selmer bot to use this command!"); + } } \ No newline at end of file diff --git a/commands/dm_handler.js b/commands/dm_handler.js index 96f3de6..057e25a 100644 --- a/commands/dm_handler.js +++ b/commands/dm_handler.js @@ -17,6 +17,8 @@ function handle_dm(message, bot) { //Only available to Selmer Bot devs, testers and "authorized" users if (docs[0] != undefined || member.roles.cache.has('944048889038774302') || member.roles.cache.has('946610800418762792')) { convoManager(client, bot, message); + } else { + message.reply("You have to be a premium subscriber to use this feature!\n_support coming soon_"); } }); });