MM-29379 Ignore channel mentions when channel is muted and channel mention setting is not updated by the user (#15992)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
66731e2740
Коммит
5a6d8387f5
@@ -907,7 +907,8 @@ func addMentionKeywordsForUser(keywords map[string][]string, profile *model.User
|
||||
|
||||
// Add @channel and @all to keywords if user has them turned on and the server allows them
|
||||
if allowChannelMentions {
|
||||
ignoreChannelMentions := channelNotifyProps[model.IGNORE_CHANNEL_MENTIONS_NOTIFY_PROP] == model.IGNORE_CHANNEL_MENTIONS_ON
|
||||
// Ignore channel mentions if channel is muted and channel mention setting is default
|
||||
ignoreChannelMentions := channelNotifyProps[model.IGNORE_CHANNEL_MENTIONS_NOTIFY_PROP] == model.IGNORE_CHANNEL_MENTIONS_ON || (channelNotifyProps[model.MARK_UNREAD_NOTIFY_PROP] == model.USER_NOTIFY_MENTION && channelNotifyProps[model.IGNORE_CHANNEL_MENTIONS_NOTIFY_PROP] == model.IGNORE_CHANNEL_MENTIONS_DEFAULT)
|
||||
|
||||
if profile.NotifyProps[model.CHANNEL_MENTIONS_NOTIFY_PROP] == "true" && !ignoreChannelMentions {
|
||||
keywords["@channel"] = append(keywords["@channel"], profile.Id)
|
||||
|
||||
Ссылка в новой задаче
Block a user