From 4d5bbd50c6615f5bb568e57353018d628f3a1a6e Mon Sep 17 00:00:00 2001 From: =Corey Hulen Date: Sun, 15 Nov 2015 18:27:30 -0800 Subject: Fixing outgoing hook --- api/post.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'api/post.go') diff --git a/api/post.go b/api/post.go index 3892d4ee8..dee26516f 100644 --- a/api/post.go +++ b/api/post.go @@ -229,6 +229,10 @@ func handlePostEventsAndForget(c *Context, post *model.Post, triggerWebhooks boo func handleWebhookEventsAndForget(c *Context, post *model.Post, team *model.Team, channel *model.Channel, user *model.User) { go func() { + if channel.Type != model.CHANNEL_OPEN { + return + } + hchan := Srv.Store.Webhook().GetOutgoingByTeam(c.Session.TeamId) hooks := []*model.OutgoingWebhook{} -- cgit v1.2.3-1-g7c22