From 7b5db6521c8a047570c968e95010d7279d486080 Mon Sep 17 00:00:00 2001 From: epenet <6771947+epenet@users.noreply.github.com> Date: Tue, 30 Jul 2024 15:29:23 +0200 Subject: [PATCH] Fix implicit-return in advantage_air (#122840) --- homeassistant/components/advantage_air/climate.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/advantage_air/climate.py b/homeassistant/components/advantage_air/climate.py index 7f9d3f2dc65..8da46cc7463 100644 --- a/homeassistant/components/advantage_air/climate.py +++ b/homeassistant/components/advantage_air/climate.py @@ -206,7 +206,8 @@ class AdvantageAirAC(AdvantageAirAcEntity, ClimateEntity): async def async_set_hvac_mode(self, hvac_mode: HVACMode) -> None: """Set the HVAC Mode and State.""" if hvac_mode == HVACMode.OFF: - return await self.async_turn_off() + await self.async_turn_off() + return if hvac_mode == HVACMode.HEAT_COOL and self.preset_mode != ADVANTAGE_AIR_MYAUTO: raise ServiceValidationError("Heat/Cool is not supported in this mode") await self.async_update_ac(