diff --git a/core/class/zwavejs.class.php b/core/class/zwavejs.class.php index 64837314..4e34c04a 100644 --- a/core/class/zwavejs.class.php +++ b/core/class/zwavejs.class.php @@ -1724,8 +1724,8 @@ public function updateCmd($_cmdId, $_value) { $_cmdId = str_replace('_', ' ', $_cmdId); $cmdId = explode('-', $_cmdId, 3); $class = $cmdId[0]; - $endpoint = $cmdId[1]; - $property = $cmdId[2]; + $endpoint = (count($cmdId) > 1) ? $cmdId[1] : null; + $property = (count($cmdId) > 2) ? $cmdId[2] : null; $value = $_value; if (isset($dictReplace[$property])) { $_cmdId = $class . '-' . $endpoint . '-' . $dictReplace[$property];