diff options
author | Joram Wilander <jwawilander@gmail.com> | 2016-06-20 17:39:13 -0400 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2016-06-20 15:39:13 -0600 |
commit | 878465b528dab56764a4e0a774a417fca870f6bc (patch) | |
tree | 5dd34f43a1b7fa8cce24a7b81ed153bba9620fd8 /api | |
parent | 86d3c32a249c9b233691186c1b8b808ee956aa00 (diff) | |
download | chat-878465b528dab56764a4e0a774a417fca870f6bc.tar.gz chat-878465b528dab56764a4e0a774a417fca870f6bc.tar.bz2 chat-878465b528dab56764a4e0a774a417fca870f6bc.zip |
Only check team Id in getChannel for non-DMs (#3382)
Diffstat (limited to 'api')
-rw-r--r-- | api/channel.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/api/channel.go b/api/channel.go index c4a5eae96..b4a5b78dc 100644 --- a/api/channel.go +++ b/api/channel.go @@ -784,7 +784,7 @@ func getChannel(c *Context, w http.ResponseWriter, r *http.Request) { member := cmresult.Data.(model.ChannelMember) data.Member = &member - if data.Channel.TeamId != c.TeamId { + if data.Channel.TeamId != c.TeamId && data.Channel.Type != model.CHANNEL_DIRECT { c.Err = model.NewLocAppError("getChannel", "api.channel.get_channel.wrong_team.app_error", map[string]interface{}{"ChannelId": id, "TeamId": c.TeamId}, "") return } |