Skip to content

Commit baaf816

Browse files
committed
Delay node dropping intermediate messages incorrectly
1 parent 7c5baac commit baaf816

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

nodes/core/core/89-delay.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@ module.exports = function(RED) {
8080
this.intervalID = -1;
8181
this.randomID = -1;
8282
this.lastSent = Date.now();
83+
this.drop = n.drop;
8384
var node = this;
8485

8586
if (this.pauseType === "delay") {
@@ -101,7 +102,7 @@ module.exports = function(RED) {
101102

102103
} else if (this.pauseType === "rate") {
103104
this.on("input", function(msg) {
104-
if (node.drop) {
105+
if (!node.drop) {
105106
if ( node.intervalID !== -1) {
106107
node.buffer.push(msg);
107108
if (node.buffer.length > 1000) {

0 commit comments

Comments
 (0)