Fix missing program name Andre0512/hon#188

This commit is contained in:
Andre Basche 2024-03-29 13:51:35 +01:00
parent 53691e383e
commit bdf9d31be3
2 changed files with 4 additions and 8 deletions

View file

@ -93,13 +93,9 @@ class Hon:
if appliance.mac_address == "": if appliance.mac_address == "":
return return
try: try:
await asyncio.gather( await appliance.load_commands()
*[ await appliance.load_attributes()
appliance.load_attributes(), await appliance.load_statistics()
appliance.load_commands(),
appliance.load_statistics(),
]
)
except (KeyError, ValueError, IndexError) as error: except (KeyError, ValueError, IndexError) as error:
_LOGGER.exception(error) _LOGGER.exception(error)
_LOGGER.error("Device data - %s", appliance_data) _LOGGER.error("Device data - %s", appliance_data)

View file

@ -45,7 +45,7 @@ class HonParameterProgram(HonParameterEnum):
for name, parameter in self._programs.items(): for name, parameter in self._programs.items():
if "iot_" in name: if "iot_" in name:
continue continue
if parameter.parameters.get("prCode"): if not parameter.parameters.get("prCode"):
continue continue
if (fav := parameter.parameters.get("favourite")) and fav.value == "1": if (fav := parameter.parameters.get("favourite")) and fav.value == "1":
continue continue