From b00b46914dd2b88bd3d09b9e82e35ac2e5b070fe Mon Sep 17 00:00:00 2001 From: Brad Rydzewski Date: Mon, 8 Jun 2015 08:42:45 -0700 Subject: [PATCH] ignore non-open pull requests --- pkg/remote/builtin/github/github.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkg/remote/builtin/github/github.go b/pkg/remote/builtin/github/github.go index fcbe4448a..9ff0fe079 100644 --- a/pkg/remote/builtin/github/github.go +++ b/pkg/remote/builtin/github/github.go @@ -301,6 +301,9 @@ func (g *GitHub) pullRequest(r *http.Request) (*common.Hook, error) { if hook.Action != "opened" && hook.Action != "synchronize" { return nil, nil } + if *hook.PullRequest.State != "open" { + return nil, nil + } repo := &common.Repo{} repo.Owner = *hook.Repo.Owner.Login