Fix color mode in flux_led light (#110096)

This commit is contained in:
Erik Montnemery 2024-02-09 14:11:27 +01:00 committed by GitHub
parent 3ca202a338
commit ae5bef6ffa
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -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}