mirror of
https://github.com/Andre0512/hon.git
synced 2026-07-03 21:55:30 +02:00
removed alias
This commit is contained in:
@@ -5,8 +5,8 @@ from typing import Any
|
||||
import voluptuous as vol # type: ignore[import-untyped]
|
||||
from homeassistant.config_entries import ConfigEntry
|
||||
from homeassistant.const import CONF_EMAIL, CONF_PASSWORD
|
||||
from homeassistant.core import HomeAssistant as HomeAssistantType
|
||||
from homeassistant.helpers import config_validation as cv, aiohttp_client
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator
|
||||
from pyhon import Hon
|
||||
|
||||
@@ -27,7 +27,7 @@ CONFIG_SCHEMA = vol.Schema(
|
||||
)
|
||||
|
||||
|
||||
async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry) -> bool:
|
||||
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||
session = aiohttp_client.async_get_clientsession(hass)
|
||||
if (config_dir := hass.config.config_dir) is None:
|
||||
raise ValueError("Missing Config Dir")
|
||||
@@ -54,14 +54,11 @@ async def async_setup_entry(hass: HomeAssistantType, entry: ConfigEntry) -> bool
|
||||
hass.data[DOMAIN][entry.unique_id] = {"hon": hon, "coordinator": coordinator}
|
||||
|
||||
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
|
||||
#for platform in PLATFORMS:
|
||||
# hass.async_create_task(
|
||||
# hass.config_entries.async_forward_entry_setups(entry, platform)
|
||||
# )
|
||||
|
||||
return True
|
||||
|
||||
|
||||
async def async_unload_entry(hass: HomeAssistantType, entry: ConfigEntry) -> bool:
|
||||
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
|
||||
refresh_token = hass.data[DOMAIN][entry.unique_id]["hon"].api.auth.refresh_token
|
||||
|
||||
hass.config_entries.async_update_entry(
|
||||
|
||||
Reference in New Issue
Block a user