Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions homeassistant/components/synology_dsm/config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,14 @@ async def async_step_user(self, user_input=None):
errors[CONF_OTP_CODE] = "otp_failed"
user_input[CONF_OTP_CODE] = None
return await self.async_step_2sa(user_input, errors)
except SynologyDSMLoginInvalidException:
except SynologyDSMLoginInvalidException as ex:
_LOGGER.error(ex)
errors[CONF_USERNAME] = "login"
except SynologyDSMRequestException:
except SynologyDSMRequestException as ex:
_LOGGER.error(ex)
errors[CONF_HOST] = "connection"
except SynologyDSMException:
except SynologyDSMException as ex:
_LOGGER.error(ex)
errors["base"] = "unknown"
except InvalidData:
errors["base"] = "missing_data"
Expand Down