Add required changes to support MQTT discovery that I previously missed. See #6481.
This commit is contained in:
parent
06bc062221
commit
ddc260b628
3 changed files with 8 additions and 0 deletions
|
@ -66,6 +66,9 @@ PLATFORM_SCHEMA = PLATFORM_SCHEMA.extend({
|
|||
@asyncio.coroutine
|
||||
def async_setup_platform(hass, config, async_add_devices, discovery_info=None):
|
||||
"""Setup a MQTT Template light."""
|
||||
if discovery_info is not None:
|
||||
config = PLATFORM_SCHEMA(discovery_info)
|
||||
|
||||
async_add_devices([MqttTemplate(
|
||||
hass,
|
||||
config.get(CONF_NAME),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue