hls.js 1.5.8-0.canary.10164 → 1.5.8-0.canary.10165

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/hls.mjs CHANGED
@@ -512,7 +512,7 @@ function enableLogs(debugConfig, context, id) {
512
512
  // Some browsers don't allow to use bind on console object anyway
513
513
  // fallback to default if needed
514
514
  try {
515
- newLogger.log(`Debug logs enabled for "${context}" in hls.js version ${"1.5.8-0.canary.10164"}`);
515
+ newLogger.log(`Debug logs enabled for "${context}" in hls.js version ${"1.5.8-0.canary.10165"}`);
516
516
  } catch (e) {
517
517
  /* log fn threw an exception. All logger methods are no-ops. */
518
518
  return createLogger();
@@ -2827,7 +2827,7 @@ function pickMostCompleteCodecName(parsedCodec, levelCodec) {
2827
2827
  if (parsedCodec && parsedCodec !== 'mp4a') {
2828
2828
  return parsedCodec;
2829
2829
  }
2830
- return levelCodec;
2830
+ return levelCodec ? levelCodec.split(',')[0] : levelCodec;
2831
2831
  }
2832
2832
  function convertAVC1ToAVCOTI(codec) {
2833
2833
  // Convert avc1 codec string from RFC-4281 to RFC-6381 for MediaSource.isTypeSupported
@@ -19764,12 +19764,13 @@ class BufferController extends Logger {
19764
19764
  }
19765
19765
  for (const trackName in tracks) {
19766
19766
  if (!sourceBuffer[trackName]) {
19767
+ var _track$levelCodec;
19767
19768
  const track = tracks[trackName];
19768
19769
  if (!track) {
19769
19770
  throw Error(`source buffer exists for track ${trackName}, however track does not`);
19770
19771
  }
19771
- // use levelCodec as first priority
19772
- let codec = track.levelCodec || track.codec;
19772
+ // use levelCodec as first priority unless it contains multiple comma-separated codec values
19773
+ let codec = ((_track$levelCodec = track.levelCodec) == null ? void 0 : _track$levelCodec.indexOf(',')) === -1 ? track.levelCodec : track.codec;
19773
19774
  if (codec) {
19774
19775
  if (trackName.slice(0, 5) === 'audio') {
19775
19776
  codec = getCodecCompatibleName(codec, this.appendSource);
@@ -28980,7 +28981,7 @@ class Hls {
28980
28981
  * Get the video-dev/hls.js package version.
28981
28982
  */
28982
28983
  static get version() {
28983
- return "1.5.8-0.canary.10164";
28984
+ return "1.5.8-0.canary.10165";
28984
28985
  }
28985
28986
 
28986
28987
  /**