diff --git a/homeassistant/components/mochad/light.py b/homeassistant/components/mochad/light.py index a966d0ad9f6..7a6f264e0bc 100644 --- a/homeassistant/components/mochad/light.py +++ b/homeassistant/components/mochad/light.py @@ -9,8 +9,8 @@ import voluptuous as vol from homeassistant.components.light import ( ATTR_BRIGHTNESS, + COLOR_MODE_BRIGHTNESS, PLATFORM_SCHEMA, - SUPPORT_BRIGHTNESS, LightEntity, ) from homeassistant.const import CONF_ADDRESS, CONF_DEVICES, CONF_NAME, CONF_PLATFORM @@ -56,6 +56,9 @@ def setup_platform( class MochadLight(LightEntity): """Representation of a X10 dimmer over Mochad.""" + _attr_color_mode = COLOR_MODE_BRIGHTNESS + _attr_supported_color_modes = {COLOR_MODE_BRIGHTNESS} + def __init__(self, hass, ctrl, dev): """Initialize a Mochad Light Device.""" @@ -89,11 +92,6 @@ class MochadLight(LightEntity): """Return true if the light is on.""" return self._state - @property - def supported_features(self): - """Return supported features.""" - return SUPPORT_BRIGHTNESS - @property def assumed_state(self): """X10 devices are normally 1-way so we have to assume the state."""