Add binary_sensor setup type hints [o-r] (#63270)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
parent
33e4251606
commit
545b10a711
24 changed files with 221 additions and 35 deletions
|
@ -1,4 +1,6 @@
|
|||
"""Support for Rflink binary sensors."""
|
||||
from __future__ import annotations
|
||||
|
||||
import voluptuous as vol
|
||||
|
||||
from homeassistant.components.binary_sensor import (
|
||||
|
@ -12,9 +14,11 @@ from homeassistant.const import (
|
|||
CONF_FORCE_UPDATE,
|
||||
CONF_NAME,
|
||||
)
|
||||
from homeassistant.core import callback
|
||||
from homeassistant.core import HomeAssistant, callback
|
||||
import homeassistant.helpers.config_validation as cv
|
||||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
import homeassistant.helpers.event as evt
|
||||
from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType
|
||||
|
||||
from . import CONF_ALIASES, RflinkDevice
|
||||
|
||||
|
@ -53,7 +57,12 @@ def devices_from_config(domain_config):
|
|||
return devices
|
||||
|
||||
|
||||
async def async_setup_platform(hass, config, async_add_entities, discovery_info=None):
|
||||
async def async_setup_platform(
|
||||
hass: HomeAssistant,
|
||||
config: ConfigType,
|
||||
async_add_entities: AddEntitiesCallback,
|
||||
discovery_info: DiscoveryInfoType | None = None,
|
||||
) -> None:
|
||||
"""Set up the Rflink platform."""
|
||||
async_add_entities(devices_from_config(config))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue