webrtcsimplewebrtc

Quit and Re-join room


I am making a video chat application using simplewebrtc. It is working fine with one call.After hanging up(webrtc.leaveRoom()) when I try to call again then it is not working.It is not executing webrtc.on('readyToCall', function() { console.log('Ready to call'); webrtc.joinRoom(room); });
So how can I ressolve this issue? Is there any issue with my old connection?


Solution

  • I found the solution.

    I made changes inside simplewebrtc. I changed the file /node_modules/simplewebrtc/src/simplewebrtc.js. I just remove comments from line 'force new connection': true.(I will never recommend this).

    Now this line looks like socketio: { 'force new connection': true } and it is working.

    thanks.