removed alias

This commit is contained in:
Vadym Melnychuk
2026-04-02 13:36:23 +03:00
parent e81b1503de
commit d3913a2e2a
11 changed files with 33 additions and 35 deletions
+4 -7
View File
@@ -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(