Minor optimisations
This commit is contained in:
@@ -28,14 +28,12 @@ class nodeClass {
|
||||
*/
|
||||
_attachInputHandler() {
|
||||
this.node.on('input', (msg, send, done) => {
|
||||
let toggleUpdate = false;
|
||||
|
||||
switch (msg.topic) {
|
||||
case "clock":
|
||||
toggleUpdate = true;
|
||||
this.source.updateState(msg.timestamp);
|
||||
send([this.source.getEffluent, null, null]);
|
||||
send([msg, null, null])
|
||||
send([msg, null, null]);
|
||||
break;
|
||||
case "Fluent":
|
||||
this.source.setInfluent = msg;
|
||||
@@ -53,7 +51,6 @@ class nodeClass {
|
||||
// Register this node as a child of the parent node
|
||||
const childId = msg.payload;
|
||||
const childObj = this.RED.nodes.getNode(childId);
|
||||
console.log(childObj.source);
|
||||
this.source.childRegistrationUtils.registerChild(childObj.source, msg.positionVsParent);
|
||||
break;
|
||||
default:
|
||||
@@ -139,6 +136,7 @@ class nodeClass {
|
||||
this.source = new_reactor; // protect from reassignment
|
||||
this.node.source = this.source;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
module.exports = nodeClass;
|
||||
Reference in New Issue
Block a user