diff --git a/homeassistant/components/file/notify.py b/homeassistant/components/file/notify.py index 4e9a2b39d1b..eb9a512b230 100644 --- a/homeassistant/components/file/notify.py +++ b/homeassistant/components/file/notify.py @@ -15,7 +15,7 @@ from homeassistant.components.notify import ( from homeassistant.const import CONF_FILENAME from homeassistant.core import HomeAssistant import homeassistant.helpers.config_validation as cv -from homeassistant.helpers.typing import ConfigType +from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType import homeassistant.util.dt as dt_util CONF_TIMESTAMP = "timestamp" @@ -29,7 +29,9 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend( def get_service( - hass: HomeAssistant, config: ConfigType, discovery_info=None + hass: HomeAssistant, + config: ConfigType, + discovery_info: DiscoveryInfoType | None = None, ) -> FileNotificationService: """Get the file notification service.""" filename: str = config[CONF_FILENAME] diff --git a/homeassistant/components/huawei_lte/notify.py b/homeassistant/components/huawei_lte/notify.py index 6e01158a800..d47249ccc51 100644 --- a/homeassistant/components/huawei_lte/notify.py +++ b/homeassistant/components/huawei_lte/notify.py @@ -11,6 +11,7 @@ from huawei_lte_api.exceptions import ResponseErrorException from homeassistant.components.notify import ATTR_TARGET, BaseNotificationService from homeassistant.const import CONF_RECIPIENT from homeassistant.core import HomeAssistant +from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType from . import Router from .const import ATTR_UNIQUE_ID, DOMAIN @@ -20,8 +21,8 @@ _LOGGER = logging.getLogger(__name__) async def async_get_service( hass: HomeAssistant, - config: dict[str, Any], - discovery_info: dict[str, Any] | None = None, + config: ConfigType, + discovery_info: DiscoveryInfoType | None = None, ) -> HuaweiLteSmsNotificationService | None: """Get the notification service.""" if discovery_info is None: