Don't add reply sender to mentions array manually

Discord already adds it to the native mentions array
This commit is contained in:
Tulir Asokan
2023-06-04 11:33:18 +03:00
parent 8c57b7a69b
commit 4c62fe8b12
3 changed files with 13 additions and 16 deletions

View File

@@ -217,8 +217,8 @@ func (portal *Portal) convertMessageBatch(log zerolog.Logger, source *User, mess
puppet := portal.bridge.GetPuppetByID(msg.Author.ID)
puppet.UpdateInfo(source, msg.Author, msg.WebhookID)
intent := puppet.IntentFor(portal)
replyTo, replySenderMXID := portal.getReplyTarget(source, "", msg.MessageReference, msg.Embeds, true)
mentions := portal.convertDiscordMentions(msg, replySenderMXID, false)
replyTo := portal.getReplyTarget(source, "", msg.MessageReference, msg.Embeds, true)
mentions := portal.convertDiscordMentions(msg, false)
ts, _ := discordgo.SnowflakeTimestamp(msg.ID)
log := log.With().