From 6d2bca0fd108535f03fb70dfb8486b10535f627d Mon Sep 17 00:00:00 2001 From: Tim Date: Sun, 24 Jan 2016 01:13:51 +0000 Subject: [PATCH] Import 3rd party library inside method --- homeassistant/components/light/lifx.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/light/lifx.py b/homeassistant/components/light/lifx.py index 09c0c829dad..afe2196b0e0 100644 --- a/homeassistant/components/light/lifx.py +++ b/homeassistant/components/light/lifx.py @@ -20,7 +20,6 @@ light: """ # pylint: disable=missing-docstring -from liffylights import liffylights import logging import colorsys from homeassistant.helpers.event import track_time_change @@ -45,6 +44,8 @@ TEMP_MAX_HASS = 500 # home assistant maximum temperature class LIFX(): def __init__(self, add_devices_callback, server_addr=None, broadcast_addr=None): + from liffylights import liffylights + self._devices = [] self._add_devices_callback = add_devices_callback