node-red-contrib-boolean-logic-ultimate
Advanced tools
Comparing version 1.1.9 to 1.1.10
@@ -0,1 +1,3 @@ | ||
const { tryCatch } = require("@project-chip/matter-node.js/common"); | ||
module.exports = function (RED) { | ||
@@ -8,2 +10,3 @@ function InjectUltimate(config) { | ||
node.topic = config.topic || "Inject"; | ||
node.outputJSON = config.outputJSON === undefined ? "{}" : config.outputJSON; | ||
setNodeStatus({ fill: "grey", shape: "dot", text: "Waiting" }); | ||
@@ -20,3 +23,3 @@ | ||
res.sendStatus(500); | ||
node.error(RED._("InjectUltimate.failed", { error: err.toString() })); | ||
node.error(RED._("InjectUltimate.failed, error:" + err.message)); | ||
} | ||
@@ -35,3 +38,10 @@ } else { | ||
node.curVal = !node.curVal; | ||
node.send([msgTrue, msgFalse, msgToggled]); | ||
try { | ||
node.outputJSON = JSON.parse(node.outputJSON); | ||
if (node.outputJSON.topic === undefined) node.outputJSON.topic = node.topic; // Add topic if not present | ||
} catch (error) { | ||
setNodeStatus({ fill: "red", shape: "dot", text: "JSON error " + error.message }); | ||
RED.log.error("node.outputJSON = JSON.parse(node.outputJSON) error:" + error.message); | ||
} | ||
node.send([msgTrue, msgFalse, msgToggled, node.outputJSON]); | ||
} | ||
@@ -38,0 +48,0 @@ |
@@ -7,2 +7,6 @@ # node-red-contrib-boolean-logic-ultimate | ||
<p> | ||
<b>Version 1.1.10</b> Mai 2024<br/> | ||
- NEW: inject node now can inject a JSON as well.</br> | ||
</p> | ||
<p> | ||
<b>Version 1.1.9</b> Mai 2024<br/> | ||
@@ -9,0 +13,0 @@ - Added samples and better description of the Math's node (in particular, to the subract function).</br> |
{ | ||
"name": "node-red-contrib-boolean-logic-ultimate", | ||
"version": "1.1.9", | ||
"version": "1.1.10", | ||
"description": "A set of Node-RED enhanced boolean logic and utility nodes, flow interruption, blinker, invert, filter, toggle etc.., with persistent values after reboot. Compatible also with Homeassistant values.", | ||
@@ -5,0 +5,0 @@ "author": "Supergiovane (https://github.com/Supergiovane)", |
@@ -1,4 +0,3 @@ | ||
# node-red-contrib-boolean-logic-ultimate | ||
![Sample Node](img/logo.png) | ||
![Logo](img/logo.png) | ||
@@ -5,0 +4,0 @@ [![NPM version][npm-version-image]][npm-url] |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Unpublished package
Supply chain riskPackage version was not found on the registry. It may exist on a different registry and need to be configured to pull from that registry.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1320103
51
1453
474
1