From 4460488f37a263b3a06828ef83f3e7349e9b7ddc Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Mon, 22 Jan 2024 12:01:08 -1000 Subject: [PATCH] Use new config entry update/abort helper in onvif (#108680) Use new config entry update/abort helper in onvif uses the new helper from https://github.com/home-assistant/core/pull/108034 --- homeassistant/components/onvif/config_flow.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/homeassistant/components/onvif/config_flow.py b/homeassistant/components/onvif/config_flow.py index e0342c5f0d408..9688a78bf3f00 100644 --- a/homeassistant/components/onvif/config_flow.py +++ b/homeassistant/components/onvif/config_flow.py @@ -146,11 +146,7 @@ async def async_step_reauth_confirm( configure_unique_id=False ) if not errors: - hass = self.hass - entry_id = entry.entry_id - hass.config_entries.async_update_entry(entry, data=self.onvif_config) - hass.async_create_task(hass.config_entries.async_reload(entry_id)) - return self.async_abort(reason="reauth_successful") + return self.async_update_reload_and_abort(entry, data=self.onvif_config) username = (user_input or {}).get(CONF_USERNAME) or entry.data[CONF_USERNAME] return self.async_show_form(