Skip to content

Commit 6eabf5c

Browse files
authored
Merge pull request #175 from mengqiy/fix_nil_pointer
fix a nil pointer issue when defaulting
2 parents 0d3ceb8 + 4926a68 commit 6eabf5c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pkg/webhook/bootstrap.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,9 @@ func (s *Server) setServerDefault() {
8282

8383
// setBootstrappingDefault does defaulting for the Server bootstrapping.
8484
func (s *Server) setBootstrappingDefault() {
85+
if s.BootstrapOptions == nil {
86+
s.BootstrapOptions = &BootstrapOptions{}
87+
}
8588
if len(s.MutatingWebhookConfigName) == 0 {
8689
s.MutatingWebhookConfigName = "mutating-webhook-configuration"
8790
}

0 commit comments

Comments
 (0)