Skip to content

Commit cfcdab1

Browse files
dishmakeraler9
andauthored
webrtc: fix endless loading in Firefox (#4707)
Co-authored-by: aler9 <[email protected]>
1 parent 1bd5feb commit cfcdab1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

internal/servers/webrtc/publish_index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@
411411
}
412412
};
413413

414-
window.addEventListener('DOMContentLoaded', () => {
414+
window.addEventListener('load', () => {
415415
if (navigator.mediaDevices === undefined) {
416416
setMessage(`can't access webcams or microphones. Make sure that WebRTC encryption is enabled.`);
417417
return;

internal/servers/webrtc/read_index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@
8080
defaultControls = video.controls;
8181
};
8282

83-
window.addEventListener('DOMContentLoaded', () => {
83+
window.addEventListener('load', () => {
8484
loadAttributesFromQuery();
8585

8686
new MediaMTXWebRTCReader({

0 commit comments

Comments
 (0)