Merge branch 'master' of github.com:nathankellenicki/node-poweredup
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Nathan Kellenicki 2019-11-10 12:31:03 -08:00
commit 4135f6e427

View File

@ -149,7 +149,7 @@ export class Hub extends EventEmitter {
public subscribe (port: string, mode?: number) {
return new Promise((resolve, reject) => {
let newMode = this._getModeForDeviceType(this._portLookup(port).type);
if (mode) {
if (mode !== undefined) {
newMode = mode;
}
this._activatePortDevice(this._portLookup(port).value, this._portLookup(port).type, newMode, 0x00, () => {