Dirnei / node-red-contrib-zigbee2mqtt-devices

Node-red nodes for controlling and managing zigbee devices managed by zigbee2mqtt
MIT License
30 stars 7 forks source link

Updated fallback checks for old ikea dimmer #90

Closed Dirnei closed 3 years ago

Dirnei commented 3 years ago

Better handling for invalid mqtt messages from z2m. Sometimes a required/expected property is missing or empty which caused an error.


@Andreas-Huber what do you think, should I rewrite those two nodes to also use the new OutputHandler class? I'm not sure (Never change a running system ^^)

Andreas-Huber commented 3 years ago

Tested the dimmer node (v1 & v2) with my dimmer. Works on my PI with Z2M 1.17.0. Code looks good.

Well, that is a good question if we should touch that. I guess they are sort of deprecated. The question is if you can mark nodes as deprecated. On the other hand, there is no reason to remove them if they don't cause problems.

My opinion regarding refactoring this: Not for now - only if we migrate the whole devices.js to typescript, then it is one go.

Dirnei commented 3 years ago

Only one of the two is more or less deprecated. But I agree, I rewrite it when we do change it to typescript sometimes.