mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Avoid emails if user status is OOO or post is an auto response (#8842)
This commit is contained in:
committed by
Carlos Tadeu Panato Junior
parent
c37d153ffb
commit
792dae23ca
@@ -216,7 +216,9 @@ func (a *App) SendNotifications(post *model.Post, team *model.Team, channel *mod
|
||||
}
|
||||
}
|
||||
|
||||
if userAllowsEmails && status.Status != model.STATUS_ONLINE && profileMap[id].DeleteAt == 0 {
|
||||
autoResponderRelated := status.Status == model.STATUS_OUT_OF_OFFICE || post.Type == model.POST_AUTO_RESPONDER
|
||||
|
||||
if userAllowsEmails && status.Status != model.STATUS_ONLINE && profileMap[id].DeleteAt == 0 && !autoResponderRelated {
|
||||
a.sendNotificationEmail(post, profileMap[id], channel, team, channelName, senderName, sender)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user