hls.js 1.5.8-0.canary.10161 → 1.5.8-0.canary.10162

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.
@@ -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.10161"}`);
515
+ newLogger.log(`Debug logs enabled for "${context}" in hls.js version ${"1.5.8-0.canary.10162"}`);
516
516
  } catch (e) {
517
517
  /* log fn threw an exception. All logger methods are no-ops. */
518
518
  return createLogger();
@@ -2268,6 +2268,9 @@ function getMediaSource(preferManagedMediaSource = true) {
2268
2268
  const mms = (preferManagedMediaSource || !self.MediaSource) && self.ManagedMediaSource;
2269
2269
  return mms || self.MediaSource || self.WebKitMediaSource;
2270
2270
  }
2271
+ function isManagedMediaSource(source) {
2272
+ return typeof self !== 'undefined' && source === self.ManagedMediaSource;
2273
+ }
2271
2274
 
2272
2275
  // from http://mp4ra.org/codecs.html
2273
2276
  // values indicate codec selection preference (lower is higher priority)
@@ -7209,7 +7212,7 @@ class BufferController extends Logger {
7209
7212
  };
7210
7213
  this.hls = hls;
7211
7214
  this.fragmentTracker = fragmentTracker;
7212
- this.appendSource = hls.config.preferManagedMediaSource && typeof self !== 'undefined' && self.ManagedMediaSource;
7215
+ this.appendSource = isManagedMediaSource(getMediaSource(hls.config.preferManagedMediaSource));
7213
7216
  this._initSourceBuffer();
7214
7217
  this.registerListeners();
7215
7218
  }
@@ -20359,7 +20362,7 @@ class Hls {
20359
20362
  * Get the video-dev/hls.js package version.
20360
20363
  */
20361
20364
  static get version() {
20362
- return "1.5.8-0.canary.10161";
20365
+ return "1.5.8-0.canary.10162";
20363
20366
  }
20364
20367
 
20365
20368
  /**