Use AddEntitiesCallback type, pt.2 (#49921)
This commit is contained in:
parent
4ed74cd2f5
commit
cbaeec2a4e
37 changed files with 91 additions and 103 deletions
|
@ -4,7 +4,7 @@ from __future__ import annotations
|
|||
from abc import abstractmethod
|
||||
from collections.abc import Mapping
|
||||
import logging
|
||||
from typing import Any, Callable
|
||||
from typing import Any
|
||||
|
||||
from pyclimacell.const import CURRENT
|
||||
|
||||
|
@ -20,7 +20,7 @@ from homeassistant.const import (
|
|||
CONF_UNIT_SYSTEM_METRIC,
|
||||
)
|
||||
from homeassistant.core import HomeAssistant
|
||||
from homeassistant.helpers.entity import Entity
|
||||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
from homeassistant.util import slugify
|
||||
|
||||
from . import ClimaCellDataUpdateCoordinator, ClimaCellEntity
|
||||
|
@ -40,7 +40,7 @@ _LOGGER = logging.getLogger(__name__)
|
|||
async def async_setup_entry(
|
||||
hass: HomeAssistant,
|
||||
config_entry: ConfigEntry,
|
||||
async_add_entities: Callable[[list[Entity], bool], None],
|
||||
async_add_entities: AddEntitiesCallback,
|
||||
) -> None:
|
||||
"""Set up a config entry."""
|
||||
coordinator = hass.data[DOMAIN][config_entry.entry_id]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue