mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 12:47:08 +00:00
Handle lutron_caseta fan speed being none (#47120)
This commit is contained in:
parent
86f8cd8037
commit
49315a90d9
@ -44,6 +44,8 @@ class LutronCasetaFan(LutronCasetaDevice, FanEntity):
|
||||
@property
|
||||
def percentage(self) -> str:
|
||||
"""Return the current speed percentage."""
|
||||
if self._device["fan_speed"] is None:
|
||||
return None
|
||||
return ordered_list_item_to_percentage(
|
||||
ORDERED_NAMED_FAN_SPEEDS, self._device["fan_speed"]
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user