mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Use async_update_reload_and_abort in bosch_shc config flow (#127436)
This commit is contained in:
parent
c957c7a515
commit
49882112ac
@ -175,12 +175,10 @@ class BoschSHCConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||||||
}
|
}
|
||||||
existing_entry = await self.async_set_unique_id(self.info["unique_id"])
|
existing_entry = await self.async_set_unique_id(self.info["unique_id"])
|
||||||
if existing_entry:
|
if existing_entry:
|
||||||
self.hass.config_entries.async_update_entry(
|
return self.async_update_reload_and_abort(
|
||||||
existing_entry,
|
existing_entry,
|
||||||
data=entry_data,
|
data=entry_data,
|
||||||
)
|
)
|
||||||
await self.hass.config_entries.async_reload(existing_entry.entry_id)
|
|
||||||
return self.async_abort(reason="reauth_successful")
|
|
||||||
|
|
||||||
return self.async_create_entry(
|
return self.async_create_entry(
|
||||||
title=cast(str, self.info["title"]),
|
title=cast(str, self.info["title"]),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user