From dce2a9e7e1146293f711c0dbd9725ac7eb0b8a16 Mon Sep 17 00:00:00 2001 From: Unknwon Date: Sun, 6 Dec 2015 23:07:02 -0500 Subject: fix wrong slack webhook payload URL --- routers/repo/webhook.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'routers/repo/webhook.go') diff --git a/routers/repo/webhook.go b/routers/repo/webhook.go index b93d6fc284..458670ad2f 100644 --- a/routers/repo/webhook.go +++ b/routers/repo/webhook.go @@ -348,7 +348,7 @@ func TestWebhook(ctx *middleware.Context) { { ID: ctx.Repo.CommitID, Message: ctx.Repo.Commit.Message(), - URL: ctx.Repo.RepoLink + "/commit/" + ctx.Repo.CommitID, + URL: ctx.Repo.Repository.FullRepoLink() + "/commit/" + ctx.Repo.CommitID, Author: &api.PayloadAuthor{ Name: ctx.Repo.Commit.Author.Name, Email: ctx.Repo.Commit.Author.Email, @@ -356,6 +356,11 @@ func TestWebhook(ctx *middleware.Context) { }, }, Repo: ctx.Repo.Repository.ComposePayload(), + Pusher: &api.PayloadAuthor{ + Name: ctx.User.Name, + Email: ctx.User.Email, + UserName: ctx.User.Name, + }, Sender: &api.PayloadUser{ UserName: ctx.User.Name, ID: ctx.User.Id, -- cgit v1.2.3