mirror of
https://github.com/home-assistant/core.git
synced 2025-07-17 10:17:09 +00:00
Fix reauth flow for Comelit VEDO (#107461)
This commit is contained in:
parent
ee9c6fa0d8
commit
8d5cdfaf36
@ -72,6 +72,7 @@ class ComelitConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||||||
_reauth_entry: ConfigEntry | None
|
_reauth_entry: ConfigEntry | None
|
||||||
_reauth_host: str
|
_reauth_host: str
|
||||||
_reauth_port: int
|
_reauth_port: int
|
||||||
|
_reauth_type: str
|
||||||
|
|
||||||
async def async_step_user(
|
async def async_step_user(
|
||||||
self, user_input: dict[str, Any] | None = None
|
self, user_input: dict[str, Any] | None = None
|
||||||
@ -109,6 +110,7 @@ class ComelitConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||||||
)
|
)
|
||||||
self._reauth_host = entry_data[CONF_HOST]
|
self._reauth_host = entry_data[CONF_HOST]
|
||||||
self._reauth_port = entry_data.get(CONF_PORT, DEFAULT_PORT)
|
self._reauth_port = entry_data.get(CONF_PORT, DEFAULT_PORT)
|
||||||
|
self._reauth_type = entry_data.get(CONF_TYPE, BRIDGE)
|
||||||
|
|
||||||
self.context["title_placeholders"] = {"host": self._reauth_host}
|
self.context["title_placeholders"] = {"host": self._reauth_host}
|
||||||
return await self.async_step_reauth_confirm()
|
return await self.async_step_reauth_confirm()
|
||||||
@ -127,6 +129,7 @@ class ComelitConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||||||
{
|
{
|
||||||
CONF_HOST: self._reauth_host,
|
CONF_HOST: self._reauth_host,
|
||||||
CONF_PORT: self._reauth_port,
|
CONF_PORT: self._reauth_port,
|
||||||
|
CONF_TYPE: self._reauth_type,
|
||||||
}
|
}
|
||||||
| user_input,
|
| user_input,
|
||||||
)
|
)
|
||||||
@ -144,6 +147,7 @@ class ComelitConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||||||
CONF_HOST: self._reauth_host,
|
CONF_HOST: self._reauth_host,
|
||||||
CONF_PORT: self._reauth_port,
|
CONF_PORT: self._reauth_port,
|
||||||
CONF_PIN: user_input[CONF_PIN],
|
CONF_PIN: user_input[CONF_PIN],
|
||||||
|
CONF_TYPE: self._reauth_type,
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
self.hass.async_create_task(
|
self.hass.async_create_task(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user