Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def subscription_update(self, _type, _params):
"""Handle reports from device."""
if _type == "attributeList":
self._attributes.update(attribute_xml_to_dict(_params))
self._state = self.mode
return True
return Switch.subscription_update(self, _type, _params)
def subscription_update(self, _type, _params):
"""Update the device attributes due to a subscription update event."""
LOG.debug("subscription_update %s %s", _type, _params)
if _type == "InsightParams":
self.insight_params = self.parse_insight_params(_params)
return True
return Switch.subscription_update(self, _type, _params)
def subscription_update(self, _type, _params):
"""Handle reports from device."""
if _type == "attributeList":
self._attributes.update(attribute_xml_to_dict(_params))
self._state = self.fan_mode
return True
return Switch.subscription_update(self, _type, _params)