Join: reduce fails if count not in first msg received

This commit is contained in:
Nick O'Leary
2018-07-26 14:13:12 +01:00
parent 9efd48fe51
commit 52f74ff7e0
2 changed files with 30 additions and 3 deletions

View File

@@ -335,9 +335,8 @@ module.exports = function(RED) {
}
var group = pending[gid];
var msgs = group.msgs;
if(parts.hasOwnProperty('count') &&
(group.count === undefined)) {
group.count = count;
if(parts.hasOwnProperty('count') && (group.count === undefined)) {
group.count = parts.count;
}
msgs.push(msg);
pending_count++;