Add support for multiple event triggers in automation (#43097)

Co-authored-by: Paulus Schoutsen <balloob@gmail.com>
This commit is contained in:
Franck Nijhof 2020-11-12 11:58:28 +01:00 committed by GitHub
parent 673ac21de4
commit 6f326a7ea4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 131 additions and 64 deletions

View file

@ -0,0 +1,15 @@
"""Helpers for automation integration."""
from homeassistant.components import blueprint
from homeassistant.core import HomeAssistant, callback
from homeassistant.helpers.singleton import singleton
from .const import DOMAIN, LOGGER
DATA_BLUEPRINTS = "automation_blueprints"
@singleton(DATA_BLUEPRINTS)
@callback
def async_get_blueprints(hass: HomeAssistant) -> blueprint.DomainBlueprints: # type: ignore
"""Get automation blueprints."""
return blueprint.DomainBlueprints(hass, DOMAIN, LOGGER) # type: ignore