Browse Source

hotRelodaInterval --> hotReloadInterval

roc 4 years ago
parent
commit
dd6769954c
1 changed files with 3 additions and 3 deletions
  1. 3 3
      transport/internet/xtls/config.go

+ 3 - 3
transport/internet/xtls/config.go

@@ -62,14 +62,14 @@ func (c *Config) BuildCertificates() []*xtls.Certificate {
 		certs = append(certs, &keyPair)
 		if !entry.OneTimeLoading {
 			var isOcspstapling bool
-			hotRelodaInterval := uint64(3600)
+			hotReloadInterval := uint64(3600)
 			if entry.OcspStapling != 0 {
-				hotRelodaInterval = entry.OcspStapling
+				hotReloadInterval = entry.OcspStapling
 				isOcspstapling = true
 			}
 			index := len(certs) - 1
 			go func(entry *Certificate, cert *xtls.Certificate, index int) {
-				t := time.NewTicker(time.Duration(hotRelodaInterval) * time.Second)
+				t := time.NewTicker(time.Duration(hotReloadInterval) * time.Second)
 				for {
 					if entry.CertificatePath != "" && entry.KeyPath != "" {
 						newCert, err := filesystem.ReadFile(entry.CertificatePath)