mirror of
https://github.com/home-assistant/core
synced 2024-10-07 10:13:38 +02:00
Make ring sync again (#16866)
This commit is contained in:
parent
e2a56721d3
commit
ba2b8512c5
@ -39,9 +39,7 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend({
|
||||
})
|
||||
|
||||
|
||||
@asyncio.coroutine
|
||||
def async_setup_platform(hass, config, async_add_entities,
|
||||
discovery_info=None):
|
||||
def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||
"""Set up a Ring Door Bell and StickUp Camera."""
|
||||
ring = hass.data[DATA_RING]
|
||||
|
||||
@ -67,14 +65,14 @@ def async_setup_platform(hass, config, async_add_entities,
|
||||
''' following cameras: {}.'''.format(cameras)
|
||||
|
||||
_LOGGER.error(err_msg)
|
||||
hass.components.persistent_notification.async_create(
|
||||
hass.components.persistent_notification.create(
|
||||
'Error: {}<br />'
|
||||
'You will need to restart hass after fixing.'
|
||||
''.format(err_msg),
|
||||
title=NOTIFICATION_TITLE,
|
||||
notification_id=NOTIFICATION_ID)
|
||||
|
||||
async_add_entities(cams, True)
|
||||
add_entities(cams, True)
|
||||
return True
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user