added support to set pull_request event from api (#3513)
This commit is contained in:
@ -165,13 +165,16 @@ func (w *Webhook) HasPullRequestEvent() bool {
|
||||
}
|
||||
|
||||
func (w *Webhook) EventsArray() []string {
|
||||
events := make([]string, 0, 2)
|
||||
events := make([]string, 0, 3)
|
||||
if w.HasCreateEvent() {
|
||||
events = append(events, "create")
|
||||
}
|
||||
if w.HasPushEvent() {
|
||||
events = append(events, "push")
|
||||
}
|
||||
if w.HasPullRequestEvent() {
|
||||
events = append(events, "pull_request")
|
||||
}
|
||||
return events
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user