From 420b06809432e90a82d2d957fd54e3698dcf9c20 Mon Sep 17 00:00:00 2001 From: Phil Date: Tue, 28 Mar 2023 20:26:57 +0200 Subject: [PATCH] Fix makeProxy returning stale proxies after assigning objects (#722) --- src/api/settings.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/api/settings.ts b/src/api/settings.ts index 0ebfe1d..0aaa490 100644 --- a/src/api/settings.ts +++ b/src/api/settings.ts @@ -133,6 +133,7 @@ function makeProxy(settings: any, root = settings, path = ""): Settings { target[p] = v; // Call any listeners that are listening to a setting of this path const setPath = `${path}${path && "."}${p}`; + delete proxyCache[setPath]; for (const subscription of subscriptions) { if (!subscription._path || subscription._path === setPath) { subscription(v, setPath);