From 17a81ef8f0a48f37d64b0ac773c5696e904a3cea Mon Sep 17 00:00:00 2001 From: Tim Wojtaszek Date: Thu, 15 Aug 2019 22:06:56 -0700 Subject: [PATCH] Address comments --- modules/parser/src/parsers/parse-timeslice-data-v2.js | 2 +- modules/parser/src/synchronizers/xviz-stream-buffer.js | 4 ---- test/modules/parser/synchronizers/xviz-stream-buffer.spec.js | 2 +- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/modules/parser/src/parsers/parse-timeslice-data-v2.js b/modules/parser/src/parsers/parse-timeslice-data-v2.js index f5fdc90ab..076b3b4c6 100644 --- a/modules/parser/src/parsers/parse-timeslice-data-v2.js +++ b/modules/parser/src/parsers/parse-timeslice-data-v2.js @@ -112,7 +112,7 @@ function parseStreamSets(streamSets, timestamp, convertPrimitive) { } } - if (streamSet.no_data_streams && noDataStreams) { + if (streamSet.no_data_streams) { noDataStreams.push(...streamSet.no_data_streams); } } diff --git a/modules/parser/src/synchronizers/xviz-stream-buffer.js b/modules/parser/src/synchronizers/xviz-stream-buffer.js index 2d45d4ab9..1f7f24147 100644 --- a/modules/parser/src/synchronizers/xviz-stream-buffer.js +++ b/modules/parser/src/synchronizers/xviz-stream-buffer.js @@ -384,10 +384,6 @@ export default class XVIZStreamBuffer { for (const streamName in timeslice.streams) { const value = timeslice.streams[streamName]; - if (value === null) { - // Explicitly delete a stream - delete timesliceAtInsertPosition.streams[streamName]; - } streams[streamName][index] = value; } for (const streamName in timeslice.videos) { diff --git a/test/modules/parser/synchronizers/xviz-stream-buffer.spec.js b/test/modules/parser/synchronizers/xviz-stream-buffer.spec.js index 0e0fde387..403b9a0c2 100644 --- a/test/modules/parser/synchronizers/xviz-stream-buffer.spec.js +++ b/test/modules/parser/synchronizers/xviz-stream-buffer.spec.js @@ -64,7 +64,7 @@ const TEST_CASES = [ timestamp: 1001, streams: {A: 1.1, B: null} }, - snapshot: {A: 1.1, C: 1} + snapshot: {A: 1.1, B: null, C: 1} }, { id: 'TS-8',