mirror of https://github.com/node-red/node-red.git
MQTT Client - missing null check
parent
0b7fa1ab5c
commit
c20128b80f
|
@ -74,7 +74,7 @@ module.exports = {
|
||||||
client.once(a,b);
|
client.once(a,b);
|
||||||
},
|
},
|
||||||
connect: function() {
|
connect: function() {
|
||||||
if (!client.isConnected() && !connecting) {
|
if (client && !client.isConnected() && !connecting) {
|
||||||
connecting = true;
|
connecting = true;
|
||||||
client.connect(options);
|
client.connect(options);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue