Disable extra=vol.ALLOW_EXTRA for MQTT platforms. (#20562)

This commit is contained in:
emontnemery 2019-01-29 18:29:02 +01:00 committed by Paulus Schoutsen
parent 48f0e8311b
commit 89fc3b2a1b
22 changed files with 67 additions and 56 deletions

View file

@ -63,7 +63,7 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
async def async_discover(discovery_payload):
"""Discover and add a MQTT binary sensor."""
try:
discovery_hash = discovery_payload[ATTR_DISCOVERY_HASH]
discovery_hash = discovery_payload.pop(ATTR_DISCOVERY_HASH)
config = PLATFORM_SCHEMA(discovery_payload)
await _async_setup_entity(config, async_add_entities, config_entry,
discovery_hash)