From 9ed82143d9e7c439dc494abfc8825c81b1eabbbf Mon Sep 17 00:00:00 2001 From: Mohammad Amoush <47069173+mamoush34@users.noreply.github.com> Date: Thu, 6 Feb 2020 18:20:43 -0500 Subject: HangUp bug fixed --- src/client/views/webcam/DashWebRTCVideo.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/client/views/webcam/DashWebRTCVideo.tsx b/src/client/views/webcam/DashWebRTCVideo.tsx index acba95354..56894c0ac 100644 --- a/src/client/views/webcam/DashWebRTCVideo.tsx +++ b/src/client/views/webcam/DashWebRTCVideo.tsx @@ -131,7 +131,7 @@ export class DashWebRTCVideo extends React.Component { console.log('Session terminated.'); - stop(); + this.stop(); this.isInitiator = false; + + if (this.localStream) { + this.localStream.getTracks().forEach(track => track.stop()); + } + + } private stop = () => { -- cgit v1.2.3-70-g09d2