PunchThrough / node-red-contrib-bean

Node-Red nodes for the LightBlue Bean
23 stars 16 forks source link

fix: callback signature need to have error as first param #12

Closed swstack closed 8 years ago

swstack commented 8 years ago

@raykamp @aderhgawen

This fixes the inability to read scratch characteristics. Users have reported that the value returned is always null. This is because the callback provided does not have the correct parameter signature... it needs to be callback(error, data). I figured this out by digging through about ~8 layers of abstraction until finally it's passed all way into the noble characteristic .read() call.

swstack commented 8 years ago

Alright tested and working. I'm expediting this PR and release so that it's no longer broken for people. :+1: