Implemented ChatGPT functionality

This commit is contained in:
Logan Cusano
2023-02-26 14:28:57 -05:00
parent c605074d05
commit 77a3c5c6fc
3 changed files with 44 additions and 38 deletions

View File

@@ -24,12 +24,13 @@ module.exports = {
try {
if (command.deferInitialReply) {
try {
if (!interaction.options.getBool('public')) await interaction.deferReply({ ephemeral: true });
if (interaction.options.getBool('public') && interaction.options.getBool('public') == false) await interaction.deferReply({ ephemeral: true });
else await interaction.deferReply({ ephemeral: false });
}
catch (err) {
if (err instanceof TypeError) {
// The public option doesn't exist in this command
await interaction.deferReply({ ephemeral: true });
await interaction.deferReply({ ephemeral: false });
} else {
throw err;
}