mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-11-19 02:12:10 +08:00
fix(frontend): preserve queued intents and fresh runtime snapshots
This commit is contained in:
@@ -78,17 +78,14 @@ export const useProxySelection = (options: ProxySelectionOptions = {}) => {
|
||||
}
|
||||
|
||||
try {
|
||||
if (isFixedProxy) {
|
||||
await mutate(() => unfixedProxy(groupName), {
|
||||
id: 'select-proxy-node',
|
||||
errorNotice: false,
|
||||
})
|
||||
} else {
|
||||
await mutate(() => selectNodeForGroup(groupName, proxyName), {
|
||||
id: 'select-proxy-node',
|
||||
errorNotice: false,
|
||||
})
|
||||
}
|
||||
const result = await mutate(
|
||||
() =>
|
||||
isFixedProxy
|
||||
? unfixedProxy(groupName)
|
||||
: selectNodeForGroup(groupName, proxyName),
|
||||
{ id: `select-proxy-node:${groupName}`, errorNotice: false },
|
||||
)
|
||||
if (!result.ok) return
|
||||
onSuccess?.()
|
||||
syncTraySelection()
|
||||
if (isFixedProxy) {
|
||||
|
||||
Reference in New Issue
Block a user