mirror of
https://github.com/home-assistant/core.git
synced 2025-07-15 09:17:10 +00:00
Fix "station is open" binary sensor in Tankerkoenig (#70928)
This commit is contained in:
parent
205a8fc752
commit
51aa070e19
@ -74,5 +74,5 @@ class StationOpenBinarySensorEntity(CoordinatorEntity, BinarySensorEntity):
|
|||||||
@property
|
@property
|
||||||
def is_on(self) -> bool | None:
|
def is_on(self) -> bool | None:
|
||||||
"""Return true if the station is open."""
|
"""Return true if the station is open."""
|
||||||
data = self.coordinator.data[self._station_id]
|
data: dict = self.coordinator.data[self._station_id]
|
||||||
return data is not None and "status" in data
|
return data is not None and data.get("status") == "open"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user