@mux/ai 0.22.0 → 0.24.0

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.
@@ -828,12 +828,12 @@ function getShotsPath(assetId) {
828
828
  }
829
829
  function mapManifestShots(shots) {
830
830
  return shots.map((shot, index) => {
831
- const { startTime, imageUrl } = shot;
831
+ const { start_time: startTime, image_url: imageUrl } = shot;
832
832
  if (typeof startTime !== "number" || !Number.isFinite(startTime)) {
833
- throw new TypeError(`Invalid shot startTime in shots manifest at index ${index}`);
833
+ throw new TypeError(`Invalid shot start_time in shots manifest at index ${index}`);
834
834
  }
835
835
  if (typeof imageUrl !== "string" || imageUrl.length === 0) {
836
- throw new TypeError(`Invalid shot imageUrl in shots manifest at index ${index}`);
836
+ throw new TypeError(`Invalid shot image_url in shots manifest at index ${index}`);
837
837
  }
838
838
  return {
839
839
  startTime,
@@ -1483,7 +1483,8 @@ function getReliableLanguageCode(track, confidenceThreshold = LOW_CONFIDENCE_THR
1483
1483
  return void 0;
1484
1484
  if (isUndeterminedLanguageCode(track.language_code))
1485
1485
  return void 0;
1486
- if (track.auto_language_confidence !== void 0 && track.auto_language_confidence < confidenceThreshold) {
1486
+ const { auto_language_confidence: autoLanguageConfidence } = track;
1487
+ if (autoLanguageConfidence !== void 0 && autoLanguageConfidence < confidenceThreshold) {
1487
1488
  return void 0;
1488
1489
  }
1489
1490
  return track.language_code;