Handle raw image link embeds like video gif embeds

This commit is contained in:
Tulir Asokan
2023-05-25 13:14:00 +03:00
parent 434f27c8b4
commit 084cde0162
2 changed files with 34 additions and 14 deletions

View File

@@ -864,7 +864,7 @@ func (portal *Portal) handleDiscordMessageUpdate(user *User, msg *discordgo.Mess
}
for _, remainingEmbed := range msg.Embeds {
// Other types of embeds are sent inline with the text message part
if getEmbedType(remainingEmbed) != EmbedVideo {
if getEmbedType(nil, remainingEmbed) != EmbedVideo {
continue
}
embedID := "video_" + remainingEmbed.URL