diff --git a/homeassistant/components/tankerkoenig/binary_sensor.py b/homeassistant/components/tankerkoenig/binary_sensor.py index 4b58ea26703..9a2b048e0b8 100644 --- a/homeassistant/components/tankerkoenig/binary_sensor.py +++ b/homeassistant/components/tankerkoenig/binary_sensor.py @@ -74,5 +74,5 @@ class StationOpenBinarySensorEntity(CoordinatorEntity, BinarySensorEntity): @property def is_on(self) -> bool | None: """Return true if the station is open.""" - data = self.coordinator.data[self._station_id] - return data is not None and "status" in data + data: dict = self.coordinator.data[self._station_id] + return data is not None and data.get("status") == "open"