From 375e82fd88fd69662eb4937906a9fcf70ffca920 Mon Sep 17 00:00:00 2001 From: Isaac Connor Date: Sat, 16 May 2026 11:47:42 -0400 Subject: [PATCH] fix: don't force HLS when user explicitly picked MP4 codec refs #4757 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 10a4f9af1 included $codec == 'MP4' in the HLS-eligibility check, which broke native mp4 playback whenever an index.m3u8 was present — picking MP4 from the dropdown silently went through HLS instead. MP4 means "play the mp4 file directly"; honor that. The MP4HLS / auto / DefaultVideo-ends-in-.m3u8 conditions still cover closed events whose stored DefaultVideo predates the C++ fix that preserves 'index.m3u8'. Reported by @IgorA100 on commit 10a4f9af1. Co-Authored-By: Claude Opus 4.7 (1M context) --- web/skins/classic/views/event.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/web/skins/classic/views/event.php b/web/skins/classic/views/event.php index 80c537055..891442acc 100644 --- a/web/skins/classic/views/event.php +++ b/web/skins/classic/views/event.php @@ -354,12 +354,13 @@ if (file_exists($Event->Path().'/objdetect.jpg')) {
Path() . '/index.m3u8') - && (($codec == 'MP4HLS') || ($codec == 'MP4') || ($codec == 'auto') + && (($codec == 'MP4HLS') || ($codec == 'auto') || str_ends_with($Event->DefaultVideo(), '.m3u8')); if ($has_hls) { $Server = $Event->Server();