def setup_platform(hass, config, add_devices, discovery_info=None):
Set up the lights from the main Qwikswitch component.
if discovery_info is None:
_LOGGER.error("Configure Qwikswitch component failed")
return False
add_devices(qwikswitch.QSUSB["light"])
return True
After Change
def setup_platform(hass, config, add_devices, discovery_info=None):
Add lights from the main Qwikswitch component.
if discovery_info is None:
logging.getLogger(__name__).error(
"Configure Qwikswitch Light component failed")
return False