Closed Shuunen closed 6 years ago
This pull-request might be unnecessary now that this pull request is accepted?
I don't now how to edit someone else his pull request. But if you want the code to be refactored it should be like:
else {
var subdevice = this._subdevices.get(msg.sid);
if (subdevice) {
subdevice._handleState(state)
} else {
// console.log('did not manage to find device, or device not yet supported')
}
}
As described in https://github.com/marvinroger/node-lumi-aqara/issues/2