Add has_firmware_update_cc bool to zwave_js/node_status cmd (#87310)

* Add `has_firmware_update_cc` bool to zwave_js/node_status cmd

* fix test

* Switch order of equality check
This commit is contained in:
Raman Gupta 2023-02-10 00:49:09 -05:00 committed by GitHub
parent 8cd5106c15
commit 8aa64c8008
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 1 deletions

View file

@ -374,6 +374,10 @@ def node_status(node: Node) -> dict[str, Any]:
"zwave_plus_version": node.zwave_plus_version,
"highest_security_class": node.highest_security_class,
"is_controller_node": node.is_controller_node,
"has_firmware_update_cc": any(
cc.id == CommandClass.FIRMWARE_UPDATE_MD.value
for cc in node.command_classes
),
}