gabrielseibel1 1 рік тому
батько
коміт
a51ddebde7
1 змінених файлів з 1 додано та 5 видалено
  1. 1 5
      models/api_host.go

+ 1 - 5
models/api_host.go

@@ -97,10 +97,6 @@ func (a *ApiHost) ConvertAPIHostToNMHost(currentHost *Host) *Host {
 	h.IsDefault = a.IsDefault
 	h.NatType = currentHost.NatType
 	h.TurnEndpoint = currentHost.TurnEndpoint
-	if h.PersistentKeepalive == 0 {
-		h.PersistentKeepalive = time.Duration(a.PersistentKeepalive)
-	} else {
-		h.PersistentKeepalive = time.Duration(a.PersistentKeepalive)
-	}
+	h.PersistentKeepalive = time.Duration(a.PersistentKeepalive)
 	return &h
 }