Axis component reflect device availability (#22401)
This commit is contained in:
parent
f4625fd561
commit
5f6037d563
10 changed files with 69 additions and 28 deletions
|
@ -37,9 +37,9 @@ async def setup_device(hass):
|
|||
1, axis.DOMAIN, 'Mock Title', ENTRY_CONFIG, 'test',
|
||||
config_entries.CONN_CLASS_LOCAL_PUSH, options=ENTRY_OPTIONS)
|
||||
device = axis.AxisNetworkDevice(hass, config_entry)
|
||||
device.api = AxisDevice(loop=loop, **config_entry.data[axis.CONF_DEVICE],
|
||||
signal=device.async_signal_callback)
|
||||
device.api = AxisDevice(loop=loop, **config_entry.data[axis.CONF_DEVICE])
|
||||
hass.data[axis.DOMAIN] = {device.serial: device}
|
||||
device.api.enable_events(event_callback=device.async_event_callback)
|
||||
|
||||
await hass.config_entries.async_forward_entry_setup(
|
||||
config_entry, 'camera')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue