Invalidate webhook cache after updating webhook (#7430)

This commit is contained in:
Joram Wilander
2017-09-14 11:47:34 -04:00
committed by GitHub
parent 9fc7845112
commit 23e64ec9aa
2 changed files with 6 additions and 0 deletions

View File

@@ -219,6 +219,7 @@ func (a *App) UpdateIncomingWebhook(oldHook, updatedHook *model.IncomingWebhook)
if result := <-a.Srv.Store.Webhook().UpdateIncoming(updatedHook); result.Err != nil {
return nil, result.Err
} else {
a.InvalidateCacheForWebhook(oldHook.Id)
return result.Data.(*model.IncomingWebhook), nil
}
}