summaryrefslogtreecommitdiffstats
path: root/routers/repo/webhook.go
diff options
context:
space:
mode:
authorRussell Aunger <raunger@gmail.com>2018-06-21 01:22:03 -0400
committerDavid Schneiderbauer <daviian@users.noreply.github.com>2018-06-21 07:22:03 +0200
commit9ae7664df7caa24825cc4cee4e4121e9f1d73e59 (patch)
tree2eff61f1174e542d4ccf45a9164e282ec1d71c5e /routers/repo/webhook.go
parentac110d1b739bdbbbac3d1156afcfa9817663e891 (diff)
downloadgitea-9ae7664df7caa24825cc4cee4e4121e9f1d73e59.tar.gz
gitea-9ae7664df7caa24825cc4cee4e4121e9f1d73e59.zip
Fix webhook type conflation. (#4285)
- Fix typo that caused Gogs hooks to be created as Gitea hooks. - Fix typo that caused Gogs hooks to be duplicated upon edit (though this bug was masked by the previous one). Signed-off-by: Russell Aunger <rba@live.com>
Diffstat (limited to 'routers/repo/webhook.go')
-rw-r--r--routers/repo/webhook.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/repo/webhook.go b/routers/repo/webhook.go
index 63450ed887..53c1afe660 100644
--- a/routers/repo/webhook.go
+++ b/routers/repo/webhook.go
@@ -210,7 +210,7 @@ func GogsHooksNewPost(ctx *context.Context, form auth.NewGogshookForm) {
Secret: form.Secret,
HookEvent: ParseHookEvent(form.WebhookForm),
IsActive: form.Active,
- HookTaskType: models.GITEA,
+ HookTaskType: models.GOGS,
OrgID: orCtx.OrgID,
}
if err := w.UpdateEvent(); err != nil {