Address late review of Adax (#53456)

Signed-off-by: Daniel Hjelseth Høyer <github@dahoiv.net>
pull/53467/head
Daniel Hjelseth Høyer 2021-07-25 12:32:50 +02:00 committed by GitHub
parent c8d2fc1e04
commit ff8affdd04
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -52,8 +52,10 @@ class ConfigFlow(config_entries.ConfigFlow, domain=DOMAIN):
errors = {}
await self.async_set_unique_id(user_input[ACCOUNT_ID])
self._abort_if_unique_id_configured()
try:
self._async_abort_entries_match({ACCOUNT_ID: user_input[ACCOUNT_ID]})
await validate_input(self.hass, user_input)
except CannotConnect:
errors["base"] = "cannot_connect"

View File

@ -3,15 +3,13 @@
"step": {
"user": {
"data": {
"host": "[%key:common::config_flow::data::host%]",
"account_id": "Account ID",
"password": "[%key:common::config_flow::data::password%]"
}
}
},
"error": {
"cannot_connect": "[%key:common::config_flow::error::cannot_connect%]",
"invalid_auth": "[%key:common::config_flow::error::invalid_auth%]"
"cannot_connect": "[%key:common::config_flow::error::cannot_connect%]"
},
"abort": {
"already_configured": "[%key:common::config_flow::abort::already_configured_device%]"