From a0b9dd9107d63d687a73f25a751cb2ce7621fdd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Johan=20Nenz=C3=A9n?= Date: Fri, 23 Aug 2024 20:50:18 +0200 Subject: [PATCH] Fix on/off state on fan --- custom_components/wellbeing/fan.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/custom_components/wellbeing/fan.py b/custom_components/wellbeing/fan.py index 4a5aaa0..e44e07d 100644 --- a/custom_components/wellbeing/fan.py +++ b/custom_components/wellbeing/fan.py @@ -119,7 +119,7 @@ async def async_set_preset_mode(self, preset_mode: str) -> None: @property def is_on(self): - return self.preset_mode is not WorkMode.OFF + return self.preset_mode != WorkMode.OFF async def async_turn_on(self, percentage: int | None = None, preset_mode: str | None = None, **kwargs) -> None: self._preset_mode = self.get_appliance.work_mode_from_preset_mode(preset_mode)