mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Move imports in tplink_lte component (#27583)
This commit is contained in:
parent
627ca3182a
commit
989c3581ac
@ -4,6 +4,7 @@ import logging
|
||||
|
||||
import aiohttp
|
||||
import attr
|
||||
import tp_connected
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.const import (
|
||||
@ -106,7 +107,6 @@ async def async_setup(hass, config):
|
||||
|
||||
async def _setup_lte(hass, lte_config, delay=0):
|
||||
"""Set up a TP-Link LTE modem."""
|
||||
import tp_connected
|
||||
|
||||
host = lte_config[CONF_HOST]
|
||||
password = lte_config[CONF_PASSWORD]
|
||||
@ -145,7 +145,6 @@ async def _login(hass, modem_data, password):
|
||||
|
||||
async def _retry_login(hass, modem_data, password):
|
||||
"""Sleep and retry setup."""
|
||||
import tp_connected
|
||||
|
||||
_LOGGER.warning("Could not connect to %s. Will keep trying.", modem_data.host)
|
||||
|
||||
|
@ -2,6 +2,7 @@
|
||||
import logging
|
||||
|
||||
import attr
|
||||
import tp_connected
|
||||
|
||||
from homeassistant.components.notify import ATTR_TARGET, BaseNotificationService
|
||||
from homeassistant.const import CONF_RECIPIENT
|
||||
@ -27,7 +28,6 @@ class TplinkNotifyService(BaseNotificationService):
|
||||
|
||||
async def async_send_message(self, message="", **kwargs):
|
||||
"""Send a message to a user."""
|
||||
import tp_connected
|
||||
|
||||
modem_data = self.hass.data[DATA_KEY].get_modem_data(self.config)
|
||||
if not modem_data:
|
||||
|
Loading…
x
Reference in New Issue
Block a user