aboutsummaryrefslogtreecommitdiff
path: root/routers/repo/webhook.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/repo/webhook.go')
-rw-r--r--routers/repo/webhook.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/routers/repo/webhook.go b/routers/repo/webhook.go
index a1b36330..6d271a4f 100644
--- a/routers/repo/webhook.go
+++ b/routers/repo/webhook.go
@@ -12,6 +12,7 @@ import (
"github.com/Unknwon/com"
+ git "github.com/gogits/git-module"
api "github.com/gogits/go-gogs-client"
"github.com/gogits/gogs/models"
@@ -341,7 +342,7 @@ func SlackHooksEditPost(ctx *middleware.Context, form auth.NewSlackHookForm) {
func TestWebhook(ctx *middleware.Context) {
p := &api.PushPayload{
- Ref: ctx.Repo.Repository.DefaultBranch,
+ Ref: git.BRANCH_PREFIX + ctx.Repo.Repository.DefaultBranch,
Before: ctx.Repo.CommitID,
After: ctx.Repo.CommitID,
Commits: []*api.PayloadCommit{