mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Inlcude team Id for fake context for incoming webhooks (#2988)
This commit is contained in:
committed by
Corey Hulen
parent
4f22cbc92b
commit
e46c1b8d52
@@ -434,6 +434,8 @@ func incomingWebhook(c *Context, w http.ResponseWriter, r *http.Request) {
|
||||
IsOAuth: false,
|
||||
}
|
||||
|
||||
c.TeamId = hook.TeamId
|
||||
|
||||
if !c.HasPermissionsToChannel(pchan, "createIncomingHook") && channel.Type != model.CHANNEL_OPEN {
|
||||
c.Err = model.NewLocAppError("incomingWebhook", "web.incoming_webhook.permissions.app_error", nil, "")
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user