diff options
Diffstat (limited to 'bridge/discord')
-rw-r--r-- | bridge/discord/handlers.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bridge/discord/handlers.go b/bridge/discord/handlers.go index 2527c0db..2313390e 100644 --- a/bridge/discord/handlers.go +++ b/bridge/discord/handlers.go @@ -90,12 +90,12 @@ func (b *Bdiscord) messageCreate(s *discordgo.Session, m *discordgo.MessageCreat // set channel name rmsg.Channel = b.getChannelName(m.ChannelID) - // set username - if !b.GetBool("UseUserName") { + fromWebhook := m.WebhookID != "" + if !fromWebhook && !b.GetBool("UseUserName") { rmsg.Username = b.getNick(m.Author, m.GuildID) } else { rmsg.Username = m.Author.Username - if b.GetBool("UseDiscriminator") { + if !fromWebhook && b.GetBool("UseDiscriminator") { rmsg.Username += "#" + m.Author.Discriminator } } |