ICU-682 Stopped sending out of channel mention warnings for system messages (#8426)

This commit is contained in:
Harrison Healey
2018-03-09 12:16:27 -05:00
committed by Derrick Anderson
parent 3922b3ac8c
commit 22f2245a26

View File

@@ -89,7 +89,7 @@ func (a *App) SendNotifications(post *model.Post, team *model.Team, channel *mod
delete(mentionedUserIds, post.UserId)
}
if len(m.OtherPotentialMentions) > 0 {
if len(m.OtherPotentialMentions) > 0 && !post.IsSystemMessage() {
if result := <-a.Srv.Store.User().GetProfilesByUsernames(m.OtherPotentialMentions, team.Id); result.Err == nil {
outOfChannelMentions := result.Data.([]*model.User)
if channel.Type != model.CHANNEL_GROUP {