Merge feat-slash-outlook #10

Merged
ChrisChrome merged 7 commits from feat-slash-outlook into main 2024-05-19 10:29:54 -06:00
Showing only changes of commit 14faf62e90 - Show all commits

View file

@ -1234,13 +1234,18 @@ discord.on("interactionCreate", async (interaction) => {
}
// Returns image, send embed with image as attachment (we need to bypass discord cache)
res.buffer().then(async (buffer) => {
const attachment = new Discord.MessageAttachment(buffer, `${type}_${day}.png`);
const embed = {
const message = {
embeds: [{
title: `${toTitleCase(type)} Outlook Day ${day}`,
image: {
url: `attachment://${type}_${day}.png`
},
color: 0x00ff00
}],
files: [{
attachment: buffer,
name: `${type}_${day}.png`
}]
}
interaction.editReply({ embeds: [embed], files: [attachment] });
});