Skip to content

Commit

Permalink
Merge pull request #224 from Arvintian/main
Browse files Browse the repository at this point in the history
fix: do nothing when validating webhooks is empty
  • Loading branch information
kilosonc authored May 6, 2024
2 parents 64e8fac + 33d511b commit 4101cd7
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/admission/webhook.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ type Webhook interface {
}

func Validating(ctx context.Context, request *Request) error {
if len(validatingWebhooks) < 1 {
return nil
}
ctx, cancelFunc := context.WithCancel(ctx)
defer cancelFunc()
finishedCount := 0
Expand Down

0 comments on commit 4101cd7

Please sign in to comment.