mirror of
https://github.com/home-assistant/core.git
synced 2026-10-07 06:50:41 -04:00
Fix error in webhook reconfiguration flow when cloudhook already exists (#183183)
This commit is contained in:
@@ -275,7 +275,7 @@ class WebhookFlowHandler(config_entries.ConfigFlow):
|
||||
# Local import to be sure cloud is loaded and setup
|
||||
from homeassistant.components.cloud import ( # noqa: PLC0415
|
||||
async_active_subscription,
|
||||
async_create_cloudhook,
|
||||
async_get_or_create_cloudhook,
|
||||
async_is_connected,
|
||||
)
|
||||
|
||||
@@ -300,7 +300,7 @@ class WebhookFlowHandler(config_entries.ConfigFlow):
|
||||
translation_domain=HOMEASSISTANT_DOMAIN,
|
||||
)
|
||||
|
||||
webhook_url = await async_create_cloudhook(self.hass, webhook_id)
|
||||
webhook_url = await async_get_or_create_cloudhook(self.hass, webhook_id)
|
||||
cloudhook = True
|
||||
else:
|
||||
webhook_url = async_generate_url(self.hass, webhook_id)
|
||||
|
||||
Reference in New Issue
Block a user