From 932b089fcfd4c9ac29b739950a9f89571850ff8e Mon Sep 17 00:00:00 2001 From: Mykola Mokhnach Date: Wed, 6 Sep 2023 21:52:35 +0200 Subject: [PATCH] Use once --- lib/tools/video-commands.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tools/video-commands.js b/lib/tools/video-commands.js index 7ece841..9b2e9bb 100644 --- a/lib/tools/video-commands.js +++ b/lib/tools/video-commands.js @@ -61,7 +61,7 @@ videoCommands.startVideoStream = async function startVideoStream (opts) { await new B((resolve, reject) => { let errorMessageChunks = []; videoStreamProcess.stderr.on('data', (data) => {errorMessageChunks.push(data);}); - videoStreamProcess.stdout.on('data', () => {resolve();}); + videoStreamProcess.stdout.once('data', () => {resolve();}); videoStreamProcess.once('error', (err) => { reject( new Error(`The IDB video streamer has failed to start. Original error: ${err.message}; stderr: ` +