From 52bc1cd18732be4087f7e1db6692ba2196a66ab0 Mon Sep 17 00:00:00 2001 From: Dominic Griesel Date: Thu, 14 Nov 2024 09:29:55 +0100 Subject: [PATCH] fix: save value change options on ZWaveNode instance --- api/lib/ZwaveClient.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/api/lib/ZwaveClient.ts b/api/lib/ZwaveClient.ts index d4a59cab1b..109e738408 100644 --- a/api/lib/ZwaveClient.ts +++ b/api/lib/ZwaveClient.ts @@ -2553,13 +2553,15 @@ class ZwaveClient extends TypedEventEmitter { props: Pick, ) { const node = this._nodes.get(nodeId) + const zwaveNode = this.getNode(nodeId) - if (!node) { + if (!zwaveNode) { throw Error('Invalid Node ID') } for (const k in props) { - node[k] = props[k] + zwaveNode[k] = props[k] + if (node) node[k] = props[k] } }