mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
Improve typing of deCONZ gateway (#69459)
* Improve typing of deCONZ gateway * Fix review comments
This commit is contained in:
parent
800bf926aa
commit
e996142592
@ -158,6 +158,9 @@ class DeconzGateway:
|
|||||||
|
|
||||||
async def async_update_device_registry(self) -> None:
|
async def async_update_device_registry(self) -> None:
|
||||||
"""Update device registry."""
|
"""Update device registry."""
|
||||||
|
if self.api.config.mac is None:
|
||||||
|
return
|
||||||
|
|
||||||
device_registry = dr.async_get(self.hass)
|
device_registry = dr.async_get(self.hass)
|
||||||
|
|
||||||
# Host device
|
# Host device
|
||||||
@ -241,7 +244,7 @@ class DeconzGateway:
|
|||||||
|
|
||||||
async def async_reset(self) -> bool:
|
async def async_reset(self) -> bool:
|
||||||
"""Reset this gateway to default state."""
|
"""Reset this gateway to default state."""
|
||||||
self.api.async_connection_status_callback = None
|
self.api.connection_status_callback = None
|
||||||
self.api.close()
|
self.api.close()
|
||||||
|
|
||||||
await self.hass.config_entries.async_unload_platforms(
|
await self.hass.config_entries.async_unload_platforms(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user