Use assignment expressions 08 (#57788)
This commit is contained in:
parent
5048bad050
commit
d5116810d4
32 changed files with 62 additions and 109 deletions
|
@ -53,8 +53,7 @@ class DiscoveryFlowHandler(config_entries.ConfigFlow):
|
|||
# Get current discovered entries.
|
||||
in_progress = self._async_in_progress()
|
||||
|
||||
has_devices = in_progress
|
||||
if not has_devices:
|
||||
if not (has_devices := in_progress):
|
||||
has_devices = await self.hass.async_add_job( # type: ignore
|
||||
self._discovery_function, self.hass
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue