void LazyProxyUpdater() { var serverList = servers.GetTrackableServerList(); var isGlobal = setting.GetBasicSetting().sysProxyMode == (int)Model.Data.Enum.SystemProxyModes.Global; var curServ = serverList.FirstOrDefault(s => s.GetConfig() == curServerConfig); if (curServ != null) { if (curServ.IsSuitableToBeUsedAsSysProxy( isGlobal, out bool isSocks, out int port)) { UpdateSysProxySetting( curServ.GetTitle(), isSocks, port); return; } } SearchForAvailableProxyServer(isGlobal, serverList.ToList()); }