Skip to content

Commit

Permalink
Fix panic in irc. Closes #1751
Browse files Browse the repository at this point in the history
  • Loading branch information
42wim committed Mar 12, 2022
1 parent e4c0ca0 commit 3012f00
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions bridge/irc/irc.go
Expand Up @@ -362,8 +362,10 @@ func (b *Birc) skipPrivMsg(event girc.Event) bool {
return true
}
// don't forward message from ourself
if event.Source.Name == b.Nick {
return true
if event.Source != nil {
if event.Source.Name == b.Nick {
return true
}
}
// don't forward messages we sent via RELAYMSG
if relayedNick, ok := event.Tags.Get("draft/relaymsg"); ok && relayedNick == b.Nick {
Expand Down

0 comments on commit 3012f00

Please sign in to comment.