From 50823045e845f684e3d3fb2bd9dc7834d899196a Mon Sep 17 00:00:00 2001 From: epenet <6771947+epenet@users.noreply.github.com> Date: Sat, 23 Apr 2022 21:06:23 +0200 Subject: [PATCH] Use ColorMode enum in isy994 (#70509) --- homeassistant/components/isy994/light.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/homeassistant/components/isy994/light.py b/homeassistant/components/isy994/light.py index 0cab8cca5df..4606ef7e8de 100644 --- a/homeassistant/components/isy994/light.py +++ b/homeassistant/components/isy994/light.py @@ -7,11 +7,7 @@ from pyisy.constants import ISY_VALUE_UNKNOWN from pyisy.helpers import NodeProperty from pyisy.nodes import Node -from homeassistant.components.light import ( - COLOR_MODE_BRIGHTNESS, - DOMAIN as LIGHT, - LightEntity, -) +from homeassistant.components.light import DOMAIN as LIGHT, ColorMode, LightEntity from homeassistant.config_entries import ConfigEntry from homeassistant.core import HomeAssistant, callback from homeassistant.helpers.entity_platform import AddEntitiesCallback @@ -51,8 +47,8 @@ async def async_setup_entry( class ISYLightEntity(ISYNodeEntity, LightEntity, RestoreEntity): """Representation of an ISY994 light device.""" - _attr_color_mode = COLOR_MODE_BRIGHTNESS - _attr_supported_color_modes = {COLOR_MODE_BRIGHTNESS} + _attr_color_mode = ColorMode.BRIGHTNESS + _attr_supported_color_modes = {ColorMode.BRIGHTNESS} def __init__(self, node: Node, restore_light_state: bool) -> None: """Initialize the ISY994 light device."""