Fix color mode in flux_led light (#110096)
This commit is contained in:
parent
3ca202a338
commit
ae5bef6ffa
1 changed files with 2 additions and 0 deletions
|
@ -12,6 +12,8 @@ from .const import FLUX_COLOR_MODE_TO_HASS, MIN_RGB_BRIGHTNESS
|
|||
|
||||
def _hass_color_modes(device: AIOWifiLedBulb) -> set[str]:
|
||||
color_modes = device.color_modes
|
||||
if not color_modes:
|
||||
return {ColorMode.ONOFF}
|
||||
return {_flux_color_mode_to_hass(mode, color_modes) for mode in color_modes}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue