Explorar el Código

if interval is 0 don't even update lh (mobile use case)

Ryan Huber hace 5 años
padre
commit
df8e45c13b
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      lighthouse.go

+ 1 - 1
lighthouse.go

@@ -197,7 +197,7 @@ func NewIpAndPortsFromNetIps(ips []udpAddr) *[]*IpAndPort {
 }
 }
 
 
 func (lh *LightHouse) LhUpdateWorker(f EncWriter) {
 func (lh *LightHouse) LhUpdateWorker(f EncWriter) {
-	if lh.amLighthouse {
+	if lh.amLighthouse || lh.interval == 0 {
 		return
 		return
 	}
 	}