refactor(proxies): untrack msg

This commit is contained in:
Zephyruso 2023-09-08 15:45:15 +08:00
parent 4ce628cec0
commit 04ccde246e

View File

@ -1,4 +1,4 @@
import { createSignal } from 'solid-js'
import { createSignal, untrack } from 'solid-js'
import {
autoCloseConns,
latencyTestTimeoutDuration,
@ -94,7 +94,7 @@ export const useProxies = () => {
if (autoCloseConns()) {
// we dont use activeConns from useConnection here for better performance
// and we use empty array to restruct msg because they are closed and they won't have speed anyway
untrack(() => {
const activeConns = restructRawMsgToConnection(
latestConnectionMsg()?.connections ?? [],
[],
@ -108,6 +108,7 @@ export const useProxies = () => {
})
mergeAllConnections(activeConns)
}
})
}
proxyGroup.now = proxyName