mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
Surepetcare, bug fix (#53695)
This commit is contained in:
parent
705e2446e5
commit
f8750daa09
@ -175,7 +175,7 @@ class DeviceConnectivity(SurePetcareBinarySensor):
|
||||
"""Get the latest data and update the state."""
|
||||
surepy_entity = self._spc.states[self._id]
|
||||
state = surepy_entity.raw_data()["status"]
|
||||
self._attr_is_on = self._attr_available = bool(self.state)
|
||||
self._attr_is_on = self._attr_available = bool(state)
|
||||
if state:
|
||||
self._attr_extra_state_attributes = {
|
||||
"device_rssi": f'{state["signal"]["device_rssi"]:.2f}',
|
||||
|
Loading…
x
Reference in New Issue
Block a user