mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Move imports to top for xfinity (#29077)
This commit is contained in:
parent
844eb6b8ef
commit
d211a29cae
@ -3,6 +3,7 @@ import logging
|
|||||||
|
|
||||||
from requests.exceptions import RequestException
|
from requests.exceptions import RequestException
|
||||||
import voluptuous as vol
|
import voluptuous as vol
|
||||||
|
from xfinity_gateway import XfinityGateway
|
||||||
|
|
||||||
import homeassistant.helpers.config_validation as cv
|
import homeassistant.helpers.config_validation as cv
|
||||||
from homeassistant.components.device_tracker import (
|
from homeassistant.components.device_tracker import (
|
||||||
@ -23,7 +24,6 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend(
|
|||||||
|
|
||||||
def get_scanner(hass, config):
|
def get_scanner(hass, config):
|
||||||
"""Validate the configuration and return an Xfinity Gateway scanner."""
|
"""Validate the configuration and return an Xfinity Gateway scanner."""
|
||||||
from xfinity_gateway import XfinityGateway
|
|
||||||
|
|
||||||
gateway = XfinityGateway(config[DOMAIN][CONF_HOST])
|
gateway = XfinityGateway(config[DOMAIN][CONF_HOST])
|
||||||
scanner = None
|
scanner = None
|
||||||
|
Loading…
x
Reference in New Issue
Block a user