Merge 422ed371f717e11a163a0cd2ce3a785864c13810 into bb01f26f068b8e083e35fdf19dc9b36f8cf67068

This commit is contained in:
Stefan Kleeschulte 2024-11-26 02:59:47 +00:00 committed by GitHub
commit 82a380c193
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -250,6 +250,10 @@ module.exports = function(RED) {
} catch (e) {
node.error(RED._("mqtt.errors.invalid-json-parse"), { payload: payload, topic: topic, qos: packet.qos, retain: packet.retain }); return;
}
if (this.brokerurl.indexOf("mqtts://") > -1 && (!this.usetls || !n.tls)) {
// Default to validating the server cert
this.verifyservercert = true;
}
} else {
node.error((RED._("mqtt.errors.invalid-json-string")), { payload: payload, topic: topic, qos: packet.qos, retain: packet.retain }); return;
}