diff options
author | Chris Duarte <csduarte@users.noreply.github.com> | 2017-11-24 09:57:02 -0800 |
---|---|---|
committer | Joram Wilander <jwawilander@gmail.com> | 2017-11-24 12:57:02 -0500 |
commit | fdbfb9a4ed722bfe138ecaf7c5b308191c13925f (patch) | |
tree | 09fdb2fcdd8542ab6ac188a03cbfc27aebd10322 /app/notification.go | |
parent | 7ac35548c8ffdcd9b0d2e260d31dbc9adc4a0065 (diff) | |
download | chat-fdbfb9a4ed722bfe138ecaf7c5b308191c13925f.tar.gz chat-fdbfb9a4ed722bfe138ecaf7c5b308191c13925f.tar.bz2 chat-fdbfb9a4ed722bfe138ecaf7c5b308191c13925f.zip |
Replace Channel Name for Team in Email Notifications (#7839)
* allow option to set channel name in email notification subject
* Added TeamName to title when UseChannelInEmailNotifications=true
Diffstat (limited to 'app/notification.go')
-rw-r--r-- | app/notification.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/notification.go b/app/notification.go index e647595bc..3b21e86c5 100644 --- a/app/notification.go +++ b/app/notification.go @@ -351,6 +351,8 @@ func (a *App) sendNotificationEmail(post *model.Post, user *model.User, channel var subjectText string if channel.Type == model.CHANNEL_DIRECT { subjectText = getDirectMessageNotificationEmailSubject(post, translateFunc, a.Config().TeamSettings.SiteName, senderName) + } else if *a.Config().EmailSettings.UseChannelInEmailNotifications { + subjectText = getNotificationEmailSubject(post, translateFunc, a.Config().TeamSettings.SiteName, team.DisplayName+" ("+channel.DisplayName+")") } else { subjectText = getNotificationEmailSubject(post, translateFunc, a.Config().TeamSettings.SiteName, team.DisplayName) } |