moved imports to top level (#27782)

This commit is contained in:
bouni 2019-10-17 15:38:58 +02:00 committed by Pascal Vizeli
parent 28cef89e03
commit 136df743e3

View file

@ -1,21 +1,22 @@
"""Platform for the Aladdin Connect cover component.""" """Platform for the Aladdin Connect cover component."""
import logging import logging
from aladdin_connect import AladdinConnectClient
import voluptuous as vol import voluptuous as vol
from homeassistant.components.cover import ( from homeassistant.components.cover import (
CoverDevice,
PLATFORM_SCHEMA, PLATFORM_SCHEMA,
SUPPORT_OPEN,
SUPPORT_CLOSE, SUPPORT_CLOSE,
SUPPORT_OPEN,
CoverDevice,
) )
from homeassistant.const import ( from homeassistant.const import (
CONF_USERNAME,
CONF_PASSWORD, CONF_PASSWORD,
CONF_USERNAME,
STATE_CLOSED, STATE_CLOSED,
STATE_OPENING,
STATE_CLOSING, STATE_CLOSING,
STATE_OPEN, STATE_OPEN,
STATE_OPENING,
) )
import homeassistant.helpers.config_validation as cv import homeassistant.helpers.config_validation as cv
@ -40,7 +41,6 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
def setup_platform(hass, config, add_entities, discovery_info=None): def setup_platform(hass, config, add_entities, discovery_info=None):
"""Set up the Aladdin Connect platform.""" """Set up the Aladdin Connect platform."""
from aladdin_connect import AladdinConnectClient
username = config.get(CONF_USERNAME) username = config.get(CONF_USERNAME)
password = config.get(CONF_PASSWORD) password = config.get(CONF_PASSWORD)