aboutsummaryrefslogtreecommitdiffstats
path: root/routers/api
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2016-07-16 01:02:55 +0800
committerUnknwon <u@gogs.io>2016-07-16 01:02:55 +0800
commit3d93532c87823159dd03e9c64a58c7bafed0fa64 (patch)
treecdf287400fd753711138486ce06766b3c789d96a /routers/api
parentfff615d5fc257c812f197a801578f32c177fbef9 (diff)
downloadgitea-3d93532c87823159dd03e9c64a58c7bafed0fa64.tar.gz
gitea-3d93532c87823159dd03e9c64a58c7bafed0fa64.zip
#3274 fix can't get webhook detail of organization
Diffstat (limited to 'routers/api')
-rw-r--r--routers/api/v1/repo/hook.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/api/v1/repo/hook.go b/routers/api/v1/repo/hook.go
index 0dac8f7cf1..0bf46977d9 100644
--- a/routers/api/v1/repo/hook.go
+++ b/routers/api/v1/repo/hook.go
@@ -98,7 +98,7 @@ func CreateHook(ctx *context.APIContext, form api.CreateHookOption) {
// https://github.com/gogits/go-gogs-client/wiki/Repositories#edit-a-hook
func EditHook(ctx *context.APIContext, form api.EditHookOption) {
- w, err := models.GetWebhookByID(ctx.Repo.Repository.ID, ctx.ParamsInt64(":id"))
+ w, err := models.GetWebhookByRepoID(ctx.Repo.Repository.ID, ctx.ParamsInt64(":id"))
if err != nil {
if models.IsErrWebhookNotExist(err) {
ctx.Status(404)