Skip to content

Commit

Permalink
Fix possible panic in mattermost. (mattermost) Fixes #1947 (#2014)
Browse files Browse the repository at this point in the history
  • Loading branch information
42wim committed Mar 11, 2023
1 parent f345eea commit 8587fa8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bridge/mattermost/mattermost.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ func (b *Bmattermost) Send(msg config.Message) (string, error) {
if err != nil {
b.Log.Errorf("getting post %s failed: %s", msg.ParentID, err)
}
if post.RootId != "" {
if post != nil && post.RootId != "" {
msg.ParentID = post.RootId
}
}
Expand Down

0 comments on commit 8587fa8

Please sign in to comment.