3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-20 00:05:04 +00:00

starboard: use embed thumbnails as image if there is no image

This commit is contained in:
Dragory 2020-12-23 02:39:44 +02:00
parent 223de75157
commit 6614cdf57f

View file

@ -36,7 +36,11 @@ export async function saveMessageToStarboard(
// Merge media and - if copy_full_embed is enabled - fields and title from the first embed in the original message
if (msg.embeds.length > 0) {
if (msg.embeds[0].image) embed.image = msg.embeds[0].image;
if (msg.embeds[0].image) {
embed.image = msg.embeds[0].image;
} else if (msg.embeds[0].thumbnail) {
embed.image = { url: msg.embeds[0].thumbnail.url };
}
if (starboard.copy_full_embed) {
if (msg.embeds[0].title) {