summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJason Blais <jason@spinpunch.com>2017-07-03 09:01:14 -0400
committerJoram Wilander <jwawilander@gmail.com>2017-07-03 09:01:14 -0400
commitac2c91c50763876c2949d4a6b67e4300be826cc2 (patch)
tree62fdef18c3c45066de68f4177cb00666b369aa70
parenta6e9a7a38fe281ccaabcf29651645dcceee1f048 (diff)
downloadchat-ac2c91c50763876c2949d4a6b67e4300be826cc2.tar.gz
chat-ac2c91c50763876c2949d4a6b67e4300be826cc2.tar.bz2
chat-ac2c91c50763876c2949d4a6b67e4300be826cc2.zip
Fix EnablChannelViewedMessages typo (#6822)
* Update config.json * Update config.go * Update config.go * Update channel.go * Update post.go * Update diagnostics.go * Update config.go
-rw-r--r--app/channel.go4
-rw-r--r--app/diagnostics.go2
-rw-r--r--app/post.go2
-rw-r--r--config/config.json4
-rw-r--r--model/config.go8
-rw-r--r--utils/config.go2
6 files changed, 11 insertions, 11 deletions
diff --git a/app/channel.go b/app/channel.go
index 5dafa1f76..2a710a3c0 100644
--- a/app/channel.go
+++ b/app/channel.go
@@ -1091,7 +1091,7 @@ func UpdateChannelLastViewedAt(channelIds []string, userId string) *model.AppErr
return result.Err
}
- if *utils.Cfg.ServiceSettings.EnablChannelViewedMessages {
+ if *utils.Cfg.ServiceSettings.EnableChannelViewedMessages {
for _, channelId := range channelIds {
message := model.NewWebSocketEvent(model.WEBSOCKET_EVENT_CHANNEL_VIEWED, "", "", userId, nil)
message.Add("channel_id", channelId)
@@ -1158,7 +1158,7 @@ func ViewChannel(view *model.ChannelView, userId string, clearPushNotifications
return result.Err
}
- if *utils.Cfg.ServiceSettings.EnablChannelViewedMessages {
+ if *utils.Cfg.ServiceSettings.EnableChannelViewedMessages {
message := model.NewWebSocketEvent(model.WEBSOCKET_EVENT_CHANNEL_VIEWED, "", "", userId, nil)
message.Add("channel_id", view.ChannelId)
go Publish(message)
diff --git a/app/diagnostics.go b/app/diagnostics.go
index 6460f36d2..97f4df0da 100644
--- a/app/diagnostics.go
+++ b/app/diagnostics.go
@@ -189,7 +189,7 @@ func trackConfig() {
"allow_edit_post": *utils.Cfg.ServiceSettings.AllowEditPost,
"post_edit_time_limit": *utils.Cfg.ServiceSettings.PostEditTimeLimit,
"enable_user_typing_messages": *utils.Cfg.ServiceSettings.EnableUserTypingMessages,
- "enable_channel_viewed_messages": *utils.Cfg.ServiceSettings.EnablChannelViewedMessages,
+ "enable_channel_viewed_messages": *utils.Cfg.ServiceSettings.EnableChannelViewedMessages,
"time_between_user_typing_updates_milliseconds": *utils.Cfg.ServiceSettings.TimeBetweenUserTypingUpdatesMilliseconds,
"cluster_log_timeout_milliseconds": *utils.Cfg.ServiceSettings.ClusterLogTimeoutMilliseconds,
"enable_post_search": *utils.Cfg.ServiceSettings.EnablePostSearch,
diff --git a/app/post.go b/app/post.go
index 841048cbc..57e4048a6 100644
--- a/app/post.go
+++ b/app/post.go
@@ -49,7 +49,7 @@ func CreatePostAsUser(post *model.Post) (*model.Post, *model.AppError) {
l4g.Error(utils.T("api.post.create_post.last_viewed.error"), post.ChannelId, post.UserId, result.Err)
}
- if *utils.Cfg.ServiceSettings.EnablChannelViewedMessages {
+ if *utils.Cfg.ServiceSettings.EnableChannelViewedMessages {
message := model.NewWebSocketEvent(model.WEBSOCKET_EVENT_CHANNEL_VIEWED, "", "", post.UserId, nil)
message.Add("channel_id", post.ChannelId)
go Publish(message)
diff --git a/config/config.json b/config/config.json
index 2424da69e..348467e98 100644
--- a/config/config.json
+++ b/config/config.json
@@ -45,7 +45,7 @@
"EnablePostSearch": true,
"EnableUserTypingMessages": true,
"EnableUserStatuses": true,
- "EnablChannelViewedMessages": true,
+ "EnableChannelViewedMessages": true,
"ClusterLogTimeoutMilliseconds": 2000
},
"ElasticSearchSettings": {
@@ -287,4 +287,4 @@
"DataRetentionSettings": {
"Enable": false
}
-} \ No newline at end of file
+}
diff --git a/model/config.go b/model/config.go
index 9e5fc3e9d..9dedaf2fc 100644
--- a/model/config.go
+++ b/model/config.go
@@ -165,7 +165,7 @@ type ServiceSettings struct {
TimeBetweenUserTypingUpdatesMilliseconds *int64
EnablePostSearch *bool
EnableUserTypingMessages *bool
- EnablChannelViewedMessages *bool
+ EnableChannelViewedMessages *bool
EnableUserStatuses *bool
ClusterLogTimeoutMilliseconds *int
}
@@ -1314,9 +1314,9 @@ func (o *Config) SetDefaults() {
*o.ServiceSettings.EnableUserTypingMessages = true
}
- if o.ServiceSettings.EnablChannelViewedMessages == nil {
- o.ServiceSettings.EnablChannelViewedMessages = new(bool)
- *o.ServiceSettings.EnablChannelViewedMessages = true
+ if o.ServiceSettings.EnableChannelViewedMessages == nil {
+ o.ServiceSettings.EnableChannelViewedMessages = new(bool)
+ *o.ServiceSettings.EnableChannelViewedMessages = true
}
if o.ServiceSettings.EnableUserStatuses == nil {
diff --git a/utils/config.go b/utils/config.go
index 66673fa4f..fa7c7fbf3 100644
--- a/utils/config.go
+++ b/utils/config.go
@@ -474,7 +474,7 @@ func getClientConfig(c *model.Config) map[string]string {
props["MaxNotificationsPerChannel"] = strconv.FormatInt(*c.TeamSettings.MaxNotificationsPerChannel, 10)
props["TimeBetweenUserTypingUpdatesMilliseconds"] = strconv.FormatInt(*c.ServiceSettings.TimeBetweenUserTypingUpdatesMilliseconds, 10)
props["EnableUserTypingMessages"] = strconv.FormatBool(*c.ServiceSettings.EnableUserTypingMessages)
- props["EnablChannelViewedMessages"] = strconv.FormatBool(*c.ServiceSettings.EnablChannelViewedMessages)
+ props["EnableChannelViewedMessages"] = strconv.FormatBool(*c.ServiceSettings.EnableChannelViewedMessages)
props["DiagnosticId"] = CfgDiagnosticId
props["DiagnosticsEnabled"] = strconv.FormatBool(*c.LogSettings.EnableDiagnostics)