mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 20:57:21 +00:00
Fix update entity prior to adding (#54015)
This commit is contained in:
parent
af565ea6bd
commit
b9e0de2eed
@ -49,7 +49,10 @@ def setup_platform(
|
||||
try:
|
||||
if not acc.login():
|
||||
raise ValueError("Username or Password is incorrect")
|
||||
add_entities(AladdinDevice(acc, door) for door in acc.get_doors())
|
||||
add_entities(
|
||||
(AladdinDevice(acc, door) for door in acc.get_doors()),
|
||||
update_before_add = True
|
||||
)
|
||||
except (TypeError, KeyError, NameError, ValueError) as ex:
|
||||
_LOGGER.error("%s", ex)
|
||||
hass.components.persistent_notification.create(
|
||||
|
Loading…
x
Reference in New Issue
Block a user