Move imports to top for nuimo_controller (#29367)

pull/29381/head
springstan 2019-12-04 00:47:11 +01:00 committed by Paulus Schoutsen
parent bd1e5fce27
commit 3205afe74e
1 changed files with 3 additions and 3 deletions

View File

@ -3,10 +3,12 @@ import logging
import threading
import time
# pylint: disable=import-error
from nuimo import NuimoController, NuimoDiscoveryManager
import voluptuous as vol
import homeassistant.helpers.config_validation as cv
from homeassistant.const import CONF_MAC, CONF_NAME, EVENT_HOMEASSISTANT_STOP
import homeassistant.helpers.config_validation as cv
_LOGGER = logging.getLogger(__name__)
@ -104,8 +106,6 @@ class NuimoThread(threading.Thread):
def _attach(self):
"""Create a Nuimo object from MAC address or discovery."""
# pylint: disable=import-error
from nuimo import NuimoController, NuimoDiscoveryManager
if self._nuimo:
self._nuimo.disconnect()