Skip to content

Commit fa492c6

Browse files
mdehustorkelo
authored andcommitted
fixed scoping issue with certPool variable (grafana#6261)
1 parent c0596d0 commit fa492c6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/login/ldap.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ func (a *ldapAuther) Dial() error {
3030
var err error
3131
var certPool *x509.CertPool
3232
if a.server.RootCACert != "" {
33-
certPool := x509.NewCertPool()
33+
certPool = x509.NewCertPool()
3434
for _, caCertFile := range strings.Split(a.server.RootCACert, " ") {
3535
if pem, err := ioutil.ReadFile(caCertFile); err != nil {
3636
return err

0 commit comments

Comments
 (0)