summaryrefslogtreecommitdiffstats
path: root/store/sql_channel_store.go
diff options
context:
space:
mode:
authorCarlos Tadeu Panato Junior <ctadeu@gmail.com>2017-03-13 14:24:30 +0100
committerChristopher Speller <crspeller@gmail.com>2017-03-13 09:24:30 -0400
commitb299bc89999818da07fdec323a74ff29819aaf65 (patch)
tree6f8d295c1dfe3464d65e5ee028d92d9c413c3a40 /store/sql_channel_store.go
parente9c6cc269b5c9fe82e5f38d63344a07365bccd6b (diff)
downloadchat-b299bc89999818da07fdec323a74ff29819aaf65.tar.gz
chat-b299bc89999818da07fdec323a74ff29819aaf65.tar.bz2
chat-b299bc89999818da07fdec323a74ff29819aaf65.zip
add update channel endpoint for APIv4 (#5624)
Diffstat (limited to 'store/sql_channel_store.go')
-rw-r--r--store/sql_channel_store.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/store/sql_channel_store.go b/store/sql_channel_store.go
index 802a5a49d..0ee6ae308 100644
--- a/store/sql_channel_store.go
+++ b/store/sql_channel_store.go
@@ -314,7 +314,7 @@ func (us SqlChannelStore) InvalidateChannel(id string) {
}
func (us SqlChannelStore) InvalidateChannelByName(teamId, name string) {
- channelCache.Remove(teamId + name)
+ channelByNameCache.Remove(teamId + name)
}
func (s SqlChannelStore) Get(id string, allowFromCache bool) StoreChannel {
@@ -684,7 +684,6 @@ func (s SqlChannelStore) getByName(teamId string, name string, includeDeleted bo
}
}
}
-
if err := s.GetReplica().SelectOne(&channel, query, map[string]interface{}{"TeamId": teamId, "Name": name}); err != nil {
if err == sql.ErrNoRows {
result.Err = model.NewLocAppError("SqlChannelStore.GetByName", MISSING_CHANNEL_ERROR, nil, "teamId="+teamId+", "+"name="+name+", "+err.Error())