delay node - change lifo property to toFront

add info to sidebar
add tests
This commit is contained in:
Dave Conway-Jones
2021-07-16 11:31:21 +01:00
parent d820f55358
commit a2b95dbb39
3 changed files with 62 additions and 1 deletions

View File

@@ -253,7 +253,7 @@ module.exports = function(RED) {
if ((max_msgs > 0) && (node.buffer.length >= max_msgs)) {
node.buffer = [];
node.error(RED._("delay.errors.too-many"), msg);
} else if (msg.lifo) {
} else if (msg.toFront === true) {
node.buffer.unshift({msg: m, send: send, done: done});
node.reportDepth();
} else {