From 0e7570ad713a91959c6b3095cf426698b7907e5f Mon Sep 17 00:00:00 2001 From: Hen <68553709+henmalib@users.noreply.github.com> Date: Sat, 13 Jul 2024 19:17:00 +0200 Subject: [PATCH] InvisibleChat: fix embeds missing decrypted content (#2655) --- src/plugins/invisibleChat.desktop/index.tsx | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/plugins/invisibleChat.desktop/index.tsx b/src/plugins/invisibleChat.desktop/index.tsx index 01199d999..c7eb29e7e 100644 --- a/src/plugins/invisibleChat.desktop/index.tsx +++ b/src/plugins/invisibleChat.desktop/index.tsx @@ -133,10 +133,12 @@ export default definePlugin({ message: message, channel: ChannelStore.getChannel(message.channel_id), onClick: async () => { - await iteratePasswords(message).then((res: string | false) => { - if (res) return void this.buildEmbed(message, res); - return void buildDecModal({ message }); - }); + const res = await iteratePasswords(message); + + if (res) + this.buildEmbed(message, res); + else + buildDecModal({ message }); } } : null; @@ -169,9 +171,9 @@ export default definePlugin({ message.embeds.push({ type: "rich", - title: "Decrypted Message", + rawTitle: "Decrypted Message", color: "0x45f5f5", - description: revealed, + rawDescription: revealed, footer: { text: "Made with ❤️ by c0dine and Sammy!", },