mirror of
https://github.com/node-red/node-red-nodes.git
synced 2023-10-10 13:36:58 +02:00
fix ternary assignment in timeswitch.
This commit is contained in:
parent
a0ff123673
commit
08ddfac83c
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name" : "node-red-node-timeswitch",
|
||||
"version" : "0.0.1",
|
||||
"version" : "0.0.2",
|
||||
"description" : "A Node-RED node to provide a simple timeswitch to schedule daily on/off events.",
|
||||
"dependencies" : {
|
||||
"suncalc": "1.6.0"
|
||||
|
@ -138,7 +138,7 @@ module.exports = function(RED) {
|
||||
|
||||
var msg = {};
|
||||
if (node.mytopic) { msg.topic = node.mytopic; }
|
||||
(proceed >= 2) ? (msg.payload = 1) : (msg.payload = 0);
|
||||
msg.payload = (process>=2) ? 1 : 0;
|
||||
node.send(msg);
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user