Move imports in awair component (#27811)
This commit is contained in:
parent
447d99a1ae
commit
54ef96e79a
1 changed files with 1 additions and 1 deletions
|
@ -4,6 +4,7 @@ from datetime import timedelta
|
||||||
import logging
|
import logging
|
||||||
import math
|
import math
|
||||||
|
|
||||||
|
from python_awair import AwairClient
|
||||||
import voluptuous as vol
|
import voluptuous as vol
|
||||||
|
|
||||||
from homeassistant.const import (
|
from homeassistant.const import (
|
||||||
|
@ -105,7 +106,6 @@ PLATFORM_SCHEMA = cv.PLATFORM_SCHEMA.extend(
|
||||||
# used at this time is the `uuid` value.
|
# used at this time is the `uuid` value.
|
||||||
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
||||||
"""Connect to the Awair API and find devices."""
|
"""Connect to the Awair API and find devices."""
|
||||||
from python_awair import AwairClient
|
|
||||||
|
|
||||||
token = config[CONF_ACCESS_TOKEN]
|
token = config[CONF_ACCESS_TOKEN]
|
||||||
client = AwairClient(token, session=async_get_clientsession(hass))
|
client = AwairClient(token, session=async_get_clientsession(hass))
|
||||||
|
|
Loading…
Add table
Reference in a new issue