diff --git a/static/sfu.js b/static/sfu.js index ee2efb7..7bf69b3 100644 --- a/static/sfu.js +++ b/static/sfu.js @@ -54,6 +54,12 @@ Connection.prototype.close = function(sendit) { while(this.timers.length > 0) clearInterval(this.timers.pop()); + this.stream.getTracks().forEach(t => { + try { + t.stop(); + } catch(e) { + } + }); this.pc.close(); if(sendit) {