From f206dfc5aeb387d2a332e97a74434542062bac44 Mon Sep 17 00:00:00 2001 From: Sergiu Toma Date: Tue, 21 Feb 2023 00:24:03 +0200 Subject: [PATCH] LH-276: Update producer close event handler --- app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app.js b/app.js index 0e38012..2d6f5f0 100644 --- a/app.js +++ b/app.js @@ -342,7 +342,7 @@ peers.on('connection', async (socket) => { // // callId - Id of the call // // kind - producer type: audio/video // socketToEmit.emit('new-producer', { callId, kind }); - receiverSocket.emit('close-producer', { callId, kind }); + videoCalls[callId].receiverSocket.emit('close-producer', { callId, kind }); }) videoCalls[callId].initiatorVideoProducer.on('producerclose', () => {