From 28bb5d139d2bbcfe5bb58b7691d9543868cce0be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Velad=20Galv=C3=A1n?= Date: Fri, 29 Sep 2023 16:58:34 +0200 Subject: [PATCH] fix(CMCD): Fix CMCD for some mimetypes in src= (#5699) --- lib/util/cmcd_manager.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/util/cmcd_manager.js b/lib/util/cmcd_manager.js index 32d092437b..85ca7653ee 100644 --- a/lib/util/cmcd_manager.js +++ b/lib/util/cmcd_manager.js @@ -331,12 +331,17 @@ shaka.util.CmcdManager = class { * @private */ getObjectTypeFromMimeType_(mimeType) { - switch (mimeType) { + switch (mimeType.toLowerCase()) { case 'video/webm': case 'video/mp4': + case 'video/mpeg': + case 'video/mp2t': return shaka.util.CmcdManager.ObjectType.MUXED; case 'application/x-mpegurl': + case 'application/vnd.apple.mpegurl': + case 'application/dash+xml': + case 'video/vnd.mpeg.dash.mpd': return shaka.util.CmcdManager.ObjectType.MANIFEST; default: