From 00845a34c8bff9215415bde2e60f1b9ecff2f6e5 Mon Sep 17 00:00:00 2001 From: Robin Bolscher Date: Wed, 8 Nov 2023 10:09:30 +0100 Subject: [PATCH] fix(meter-reset): return after success --- lib/ZwaveDevice.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/ZwaveDevice.js b/lib/ZwaveDevice.js index b62a296..d4e893a 100644 --- a/lib/ZwaveDevice.js +++ b/lib/ZwaveDevice.js @@ -1061,6 +1061,9 @@ class ZwaveDevice extends Homey.Device { if (commandClassMeter && commandClassMeter.hasOwnProperty('METER_RESET')) { const result = await commandClassMeter.METER_RESET({}); if (result !== 'TRANSMIT_COMPLETE_OK') throw result; + + // Return if reset was successful + return; } throw new Error('missing_meter_reset_command'); }