From cfd99affa5086506bae8188976f9e65281cc2ee9 Mon Sep 17 00:00:00 2001 From: epenet <6771947+epenet@users.noreply.github.com> Date: Tue, 3 Jun 2025 09:26:49 +0200 Subject: [PATCH] Tweak --- blog/2025-06-03-deprecate-verify-domain-control.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/blog/2025-06-03-deprecate-verify-domain-control.md b/blog/2025-06-03-deprecate-verify-domain-control.md index 1ea9c0d7..20732cda 100644 --- a/blog/2025-06-03-deprecate-verify-domain-control.md +++ b/blog/2025-06-03-deprecate-verify-domain-control.md @@ -29,7 +29,8 @@ Minimum change is to simply adjust the decorator # Old # def register_services(hass: HomeAssistant) -> None: # @verify_domain_control(hass, DOMAIN) -# async def do_action(hass: HomeAssistant, call: ServiceCall) -> None: +# async def do_action(call: ServiceCall) -> None: +# entries = hass.config_entries.async_entries(DOMAIN) # ... # hass.services.async_register(...) @@ -37,6 +38,7 @@ Minimum change is to simply adjust the decorator def register_services(hass: HomeAssistant) -> None: @verify_domain_entity_control(DOMAIN) async def do_action(call: ServiceCall) -> None: + entries = hass.config_entries.async_entries(DOMAIN) ... hass.services.async_register(...)