evaluate retained messages too
This commit is contained in:
@ -70,11 +70,11 @@ class MqttHandler {
|
||||
})
|
||||
})
|
||||
this.mqttClient.on('message', (topic: string, payload: Buffer, packet : Mqtt.IPublishPacket): void => {
|
||||
if (! packet.retain) {
|
||||
// if (! packet.retain) {
|
||||
let payloadStr : string = payload.toString('UTF-8')
|
||||
// logger.info(`Message received on topic ${topic}: ${payload}`)
|
||||
this.processMessage(topic, payloadStr)
|
||||
}
|
||||
// }
|
||||
})
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user