Use typed config entry in Trafikverket Camera (#134299)

This commit is contained in:
G Johansson 2024-12-30 22:48:22 +01:00 committed by GitHub
parent 820f04e1e1
commit f2e856b8a2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -34,12 +34,12 @@ async def async_setup_entry(hass: HomeAssistant, entry: TVCameraConfigEntry) ->
return True
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
async def async_unload_entry(hass: HomeAssistant, entry: TVCameraConfigEntry) -> bool:
"""Unload Trafikverket Camera config entry."""
return await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
async def async_migrate_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
async def async_migrate_entry(hass: HomeAssistant, entry: TVCameraConfigEntry) -> bool:
"""Migrate old entry."""
api_key = entry.data[CONF_API_KEY]
web_session = async_get_clientsession(hass)