Use ColorMode enum in kulersky (#70514)

pull/70543/head
epenet 2022-04-23 21:17:31 +02:00 committed by GitHub
parent 7e7519fe05
commit cf4232467c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@ import pykulersky
from homeassistant.components.light import (
ATTR_BRIGHTNESS,
ATTR_RGBW_COLOR,
COLOR_MODE_RGBW,
ColorMode,
LightEntity,
)
from homeassistant.config_entries import ConfigEntry
@ -67,8 +67,8 @@ class KulerskyLight(LightEntity):
"""Initialize a Kuler Sky light."""
self._light = light
self._available = False
self._attr_supported_color_modes = {COLOR_MODE_RGBW}
self._attr_color_mode = COLOR_MODE_RGBW
self._attr_supported_color_modes = {ColorMode.RGBW}
self._attr_color_mode = ColorMode.RGBW
async def async_added_to_hass(self) -> None:
"""Run when entity about to be added to hass."""