particle-iot / node-red-contrib-particle-official

Official Node-RED Particle nodes
MIT License
12 stars 7 forks source link

Fixed Node Red crash due to re-auth process calling event listener with undefined callback #6

Open sberkovitz opened 1 year ago

sberkovitz commented 1 year ago

From reading forums, this appears to have started in Node Red 3.0. Node Red will crash every 2 hours with this added.

Reviewing the code, I can see no reason for the listenToEventStream being called only during the re-auth process as there is no callback. I removed this unnecessary call

I tested the subscribe node and it works as-expected