diff --git a/discord/plugin.json b/discord/plugin.json index 0c2f6f7..a2abc15 100644 --- a/discord/plugin.json +++ b/discord/plugin.json @@ -2,7 +2,7 @@ "main": "plugin.js", "name": "discord", "description": "Discord Service for Squeebot 3", - "version": "1.1.0", + "version": "1.1.1", "tags": ["service", "discord"], "dependencies": ["control?"], "npmDependencies": ["discord.js@^12.5.1"] diff --git a/discord/plugin.ts b/discord/plugin.ts index 163ec5f..c1164f5 100644 --- a/discord/plugin.ts +++ b/discord/plugin.ts @@ -168,6 +168,10 @@ class DiscordProtocol extends Protocol { return; } } + // Discord supports sending objects to the channel for things like embeds + else if (typeof data[0] === 'object') { + response = data[0]; + } msg.data.channel.send(response).catch((e: Error) => { logger.error(e);