Use EntityFeature enum in components (i**) (#69409)
This commit is contained in:
parent
75eec850c1
commit
e6d8aa34fa
15 changed files with 109 additions and 167 deletions
|
@ -7,8 +7,8 @@ from homeassistant.components.light import (
|
|||
COLOR_MODE_BRIGHTNESS,
|
||||
COLOR_MODE_ONOFF,
|
||||
DOMAIN,
|
||||
SUPPORT_EFFECT,
|
||||
LightEntity,
|
||||
LightEntityFeature,
|
||||
)
|
||||
from homeassistant.config_entries import ConfigEntry
|
||||
from homeassistant.core import HomeAssistant
|
||||
|
@ -102,6 +102,6 @@ class HassAqualinkLight(AqualinkEntity, LightEntity):
|
|||
def supported_features(self) -> int:
|
||||
"""Return the list of features supported by the light."""
|
||||
if self.dev.is_color:
|
||||
return SUPPORT_EFFECT
|
||||
return LightEntityFeature.EFFECT
|
||||
|
||||
return 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue