From a0c3bb77bcf035d34500b2b5c524f394c0d2ebaf Mon Sep 17 00:00:00 2001 From: toast-ts <96593068+toast-ts@users.noreply.github.com> Date: Tue, 15 Aug 2023 03:15:23 +1000 Subject: [PATCH] Return an error if tag doesn't exist --- src/commands/tag.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/commands/tag.ts b/src/commands/tag.ts index 5276f93..44adb8c 100644 --- a/src/commands/tag.ts +++ b/src/commands/tag.ts @@ -17,6 +17,7 @@ export default { }; ({ send: async()=>{ + if (!await tagData()) return interaction.reply({content:'This tag is not available in the database.',ephemeral:true}); let targetField = ''; const targetMember = interaction.options.getMember('target_user'); if (targetMember) targetField = `*This tag is for <@${targetMember.id}>*`;