From 4f8aee8ca188710b6573921b3c8fd690157dcfef Mon Sep 17 00:00:00 2001 From: Ubuntu Date: Mon, 5 Aug 2024 08:50:38 +0000 Subject: [PATCH] fix crash --- server/room.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/room.ts b/server/room.ts index 172918f344..666f2faa59 100644 --- a/server/room.ts +++ b/server/room.ts @@ -513,8 +513,8 @@ export class Room { // prefer reddit m3u8 streams over the mp4 links as the m3u8 streams contain audio. data = reddit_m3u8 || reddit_mp4 || data; } else if ( - data.startsWith('https://www.twitch.tv') || - data.startsWith('https://twitch.tv') + data?.startsWith('https://www.twitch.tv') || + data?.startsWith('https://twitch.tv') ) { try { // Extract m3u8 data