hls.js 1.5.18 → 1.5.20

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.
@@ -326,14 +326,7 @@ export function matchesOption(
326
326
  track: MediaPlaylist,
327
327
  ) => boolean,
328
328
  ): boolean {
329
- const {
330
- groupId,
331
- name,
332
- lang,
333
- assocLang,
334
- characteristics,
335
- default: isDefault,
336
- } = option;
329
+ const { groupId, name, lang, assocLang, default: isDefault } = option;
337
330
  const forced = (option as SubtitleSelectionOption).forced;
338
331
  return (
339
332
  (groupId === undefined || track.groupId === groupId) &&
@@ -342,8 +335,11 @@ export function matchesOption(
342
335
  (lang === undefined || track.assocLang === assocLang) &&
343
336
  (isDefault === undefined || track.default === isDefault) &&
344
337
  (forced === undefined || track.forced === forced) &&
345
- (characteristics === undefined ||
346
- characteristicsMatch(characteristics, track.characteristics)) &&
338
+ (!('characteristics' in option) ||
339
+ characteristicsMatch(
340
+ option.characteristics || '',
341
+ track.characteristics,
342
+ )) &&
347
343
  (matchPredicate === undefined || matchPredicate(option, track))
348
344
  );
349
345
  }