Bump python matter server to 1.0.8 (#84692)

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
This commit is contained in:
Marcel van der Veldt 2022-12-28 18:29:37 +01:00 committed by GitHub
parent 5bdaad9c13
commit 0e9c6b2bba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 44 additions and 26 deletions

View file

@ -56,7 +56,8 @@ class MatterSwitch(MatterEntity, SwitchEntity):
@callback
def _update_from_device(self) -> None:
"""Update from device."""
self._attr_is_on = self._device_type_instance.get_cluster(clusters.OnOff).onOff
cluster = self._device_type_instance.get_cluster(clusters.OnOff)
self._attr_is_on = cluster.onOff if cluster else None
@dataclass