mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 03:07:37 +00:00
Improve type hint in entity_component (#80596)
Imrpove type hint in entity_component
This commit is contained in:
parent
454394a242
commit
eb93372cd6
@ -37,6 +37,7 @@ _EntityT = TypeVar("_EntityT", bound=entity.Entity)
|
||||
async def async_update_entity(hass: HomeAssistant, entity_id: str) -> None:
|
||||
"""Trigger an update for an entity."""
|
||||
domain = entity_id.split(".", 1)[0]
|
||||
entity_comp: EntityComponent[entity.Entity] | None
|
||||
entity_comp = hass.data.get(DATA_INSTANCES, {}).get(domain)
|
||||
|
||||
if entity_comp is None:
|
||||
|
Loading…
x
Reference in New Issue
Block a user