Update packages/node_modules/@node-red/nodes/core/network/10-mqtt.js

Co-authored-by: Stephen McLaughlin <44235289+Steve-Mcl@users.noreply.github.com>
This commit is contained in:
Phil Day 2022-05-09 16:20:27 +01:00 committed by GitHub
parent 3d3090a8f2
commit 98d524e82d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 6 deletions

View File

@ -1008,13 +1008,13 @@ module.exports = function(RED) {
// so we can't use removeAllListeners() wothout breaking it
/**
* Add an event handlers to the MQTT.js client
* @param {string} [event] The name of the event (optional)
* @param {function} [handler] The handler for this event
* Add an event handler to the MQTT.js client
* @param {string} event The name of the event
* @param {function} handler The handler for this event
*/
node._clientOn = function(event, f) {
node.clientListeners.push({event, f})
node.client.on(event, f)
node._clientOn = function(event, handler) {
node.clientListeners.push({event, handler})
node.client.on(event, handler)
}
/**