We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 110fe39 commit 0498a67Copy full SHA for 0498a67
1 file changed
jenkins/webhook-proxy/main.go
@@ -516,10 +516,15 @@ func (s *Server) HandleRoot() http.HandlerFunc {
516
updatePipeline = true
517
resourceVersion = bc.Metadata.ResourceVersion
518
}
519
- if bc.Spec.Triggers.Type == "" {
520
- log.Println(requestID, fmt.Sprintf(
521
- "Trigger secret does not exists, updating pipeline",
522
- ))
+ triggerExists := false
+ for _, trigger := range bc.Spec.Triggers {
+ if trigger.Type != "" {
+ triggerExists = true
523
+ break
524
+ }
525
526
+ if !triggerExists {
527
+ log.Println(requestID, "Trigger secret does not exist, updating pipeline")
528
529
530
0 commit comments