diff options
author | =Corey Hulen <corey@hulen.com> | 2016-01-20 10:04:17 -0600 |
---|---|---|
committer | =Corey Hulen <corey@hulen.com> | 2016-01-20 10:04:17 -0600 |
commit | 11c035aef45fbc6dfbc360123611108a199eca79 (patch) | |
tree | e0edabe17ad251a029214ed98a9f7ea66d880a91 /api/webhook.go | |
parent | 640d3018c9a75e7c85da55c3483396e31a6de994 (diff) | |
download | chat-11c035aef45fbc6dfbc360123611108a199eca79.tar.gz chat-11c035aef45fbc6dfbc360123611108a199eca79.tar.bz2 chat-11c035aef45fbc6dfbc360123611108a199eca79.zip |
PLT-7 adding loc db calls for oauth table
Diffstat (limited to 'api/webhook.go')
-rw-r--r-- | api/webhook.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/api/webhook.go b/api/webhook.go index 7c7d89866..284563ddd 100644 --- a/api/webhook.go +++ b/api/webhook.go @@ -41,8 +41,8 @@ func createIncomingHook(c *Context, w http.ResponseWriter, r *http.Request) { return } - cchan := Srv.Store.Channel().Get(hook.ChannelId) - pchan := Srv.Store.Channel().CheckPermissionsTo(c.Session.TeamId, hook.ChannelId, c.Session.UserId) + cchan := Srv.Store.Channel().Get(c.T, hook.ChannelId) + pchan := Srv.Store.Channel().CheckPermissionsTo(c.T, c.Session.TeamId, hook.ChannelId, c.Session.UserId) hook.UserId = c.Session.UserId hook.TeamId = c.Session.TeamId @@ -145,8 +145,8 @@ func createOutgoingHook(c *Context, w http.ResponseWriter, r *http.Request) { hook.TeamId = c.Session.TeamId if len(hook.ChannelId) != 0 { - cchan := Srv.Store.Channel().Get(hook.ChannelId) - pchan := Srv.Store.Channel().CheckPermissionsTo(c.Session.TeamId, hook.ChannelId, c.Session.UserId) + cchan := Srv.Store.Channel().Get(c.T, hook.ChannelId) + pchan := Srv.Store.Channel().CheckPermissionsTo(c.T, c.Session.TeamId, hook.ChannelId, c.Session.UserId) var channel *model.Channel if result := <-cchan; result.Err != nil { |