Implement WebRTC URL resolution and update stream playback logic across components and API routes

This commit is contained in:
Nikita
2025-12-23 11:32:08 -08:00
parent f45c28f941
commit 93bd99f9ed
10 changed files with 133 additions and 30 deletions

View File

@@ -111,7 +111,11 @@ function StreamPage() {
const stream = data?.stream ?? null
const playback = stream?.playback ?? null
const fallbackPlayback = stream?.hls_url
? resolveStreamPlayback({ hlsUrl: stream.hls_url, webrtcUrl: null })
? resolveStreamPlayback({
hlsUrl: stream.hls_url,
webrtcUrl: null,
preferWebRtc: false,
})
: null
const activePlayback =
playback?.type === "webrtc" && webRtcFailed
@@ -179,7 +183,6 @@ function StreamPage() {
)
}
const { user } = data
const showPlayer =
activePlayback?.type === "cloudflare" ||
activePlayback?.type === "webrtc" ||