diff --git a/homeassistant/components/light/yeelight.py b/homeassistant/components/light/yeelight.py index 1275d854e0b..15f2d24fa8a 100644 --- a/homeassistant/components/light/yeelight.py +++ b/homeassistant/components/light/yeelight.py @@ -276,7 +276,9 @@ class YeelightLight(Light): @property def _properties(self) -> dict: - return self._bulb.last_properties + if self._bulb_device is None: + return {} + return self._bulb_device.last_properties # F821: https://github.com/PyCQA/pyflakes/issues/373 @property