nginxinc / nginx-loadbalancer-kubernetes

A Kubernetes Controller to synchronize NGINX+ Resources with Kubernetes Ingress Resources
Apache License 2.0
58 stars 19 forks source link

Initialize Certificates Map to Avoid Nil Map Panic #128

Open ciroque opened 11 months ago

ciroque commented 11 months ago

In the NewCertificates method, the Certificates field is initialized to nil, which could cause a panic when trying to insert key-value pairs into the map. It should be initialized to an empty map instead: Certificates: make(map[string]map[string][]byte).