evaluate retained messages too

This commit is contained in:
2018-04-09 15:56:46 +02:00
parent b8dcece64e
commit aad115f7b0

View File

@ -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)
}
// }
})
}