Skip to content

Commit

Permalink
Ignore updates to outgoing webhook messages
Browse files Browse the repository at this point in the history
  • Loading branch information
tulir committed May 15, 2023
1 parent ad8efb8 commit cf7ae7c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions portal.go
Original file line number Diff line number Diff line change
Expand Up @@ -834,6 +834,13 @@ func (portal *Portal) handleDiscordMessageUpdate(user *User, msg *discordgo.Mess
} else {
portal.recentMessages.Replace(msg.ID, msg)
}
if msg.Author.ID == portal.RelayWebhookID {
log.Debug().
Str("message_id", msg.ID).
Str("author_id", msg.Author.ID).
Msg("Dropping edit from relay webhook")
return
}

intent := portal.bridge.GetPuppetByID(msg.Author.ID).IntentFor(portal)

Expand Down

0 comments on commit cf7ae7c

Please sign in to comment.