diff --git a/custom_components/localtuya/fan.py b/custom_components/localtuya/fan.py index 7ae7d12a9..49b5c1e5f 100644 --- a/custom_components/localtuya/fan.py +++ b/custom_components/localtuya/fan.py @@ -1,4 +1,5 @@ """Platform to locally control Tuya-based fan devices.""" + import logging import math from functools import partial @@ -188,9 +189,9 @@ async def async_set_direction(self, direction): self.schedule_update_ha_state() @property - def supported_features(self) -> int: + def supported_features(self) -> FanEntityFeature: """Flag supported features.""" - features = 0 + features = FanEntityFeature(0) if self.has_config(CONF_FAN_OSCILLATING_CONTROL): features |= FanEntityFeature.OSCILLATE