From a4be39268a496055b76e0679fe1b2e060ee6c2a7 Mon Sep 17 00:00:00 2001 From: YetAnotherZephyruso <176294927+YetAnotherZephyruso@users.noreply.github.com> Date: Mon, 5 Aug 2024 09:39:49 +0800 Subject: [PATCH] fix: nil for nextnode (#892) --- src/signals/proxies.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/signals/proxies.ts b/src/signals/proxies.ts index 9196130..ea85c93 100644 --- a/src/signals/proxies.ts +++ b/src/signals/proxies.ts @@ -248,7 +248,13 @@ export const useProxies = () => { } while (node.now && node.now !== node.name) { - node = proxyNodeMap()[node.now] + const nextNode = proxyNodeMap()[node.now] + + if (!nextNode) { + return node.name + } + + node = nextNode } return node.name