diff options
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/proxies/ProxyGroup.tsx | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/components/proxies/ProxyGroup.tsx b/src/components/proxies/ProxyGroup.tsx index 2b00bae..5c8fa25 100644 --- a/src/components/proxies/ProxyGroup.tsx +++ b/src/components/proxies/ProxyGroup.tsx @@ -73,9 +73,15 @@ function ProxyGroupImpl({ const testLatency = useCallback(async () => { setIsTestingLatency(true); try { - await proxiesAPI.requestDelayForProxyGroup(apiConfig,name); - await dispatch(fetchProxies(apiConfig)); - } catch (err) {} + if (version.meta==true){ + await proxiesAPI.requestDelayForProxyGroup(apiConfig,name); + await dispatch(fetchProxies(apiConfig));} + else{ + await proxiesAPI.requestDelayForProxy(apiConfig,all); + await dispatch(fetchProxies(apiConfig)); + } + } + catch (err) {} setIsTestingLatency(false); }, [apiConfig, dispatch, name]); |
