chore: do not load cert pool if not necessary
This commit is contained in:
parent
ae13418929
commit
2e1c5091c3
@ -40,6 +40,9 @@ func ResetCertificate() {
|
||||
}
|
||||
|
||||
func getCertPool() *x509.CertPool {
|
||||
if len(trustCerts) == 0 {
|
||||
return nil
|
||||
}
|
||||
if certPool == nil {
|
||||
mutex.Lock()
|
||||
defer mutex.Unlock()
|
||||
|
Reference in New Issue
Block a user