mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-07 03:35:26 +03:00
Close pc as well
This commit is contained in:
parent
5deda8a855
commit
5fbf43d352
@ -85,6 +85,10 @@ export default function WebRtcPlayer({ camera, width, height }) {
|
|||||||
pc.setRemoteDescription({ type: 'answer', sdp: msg.value });
|
pc.setRemoteDescription({ type: 'answer', sdp: msg.value });
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
ws.addEventListener('close', () => {
|
||||||
|
pc.close();
|
||||||
|
})
|
||||||
}, [PeerConnection, ws]);
|
}, [PeerConnection, ws]);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user