mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
parent
aec885a467
commit
08b169a7ad
@ -46,6 +46,7 @@ class YaleDoorlock(YaleEntity, LockEntity):
|
||||
"""Initialize the Yale Lock Device."""
|
||||
super().__init__(coordinator, data)
|
||||
self._attr_code_format = f"^\\d{code_format}$"
|
||||
self.lock_name = data["name"]
|
||||
|
||||
async def async_unlock(self, **kwargs: Any) -> None:
|
||||
"""Send unlock command."""
|
||||
@ -65,7 +66,7 @@ class YaleDoorlock(YaleEntity, LockEntity):
|
||||
|
||||
try:
|
||||
get_lock = await self.hass.async_add_executor_job(
|
||||
self.coordinator.yale.lock_api.get, self._attr_name
|
||||
self.coordinator.yale.lock_api.get, self.lock_name
|
||||
)
|
||||
if command == "locked":
|
||||
lock_state = await self.hass.async_add_executor_job(
|
||||
|
Loading…
x
Reference in New Issue
Block a user