mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
Fixed wrong array typing
This commit is contained in:
parent
340522a471
commit
062ea29ad2
1 changed files with 4 additions and 1 deletions
|
@ -640,10 +640,13 @@ function tryRemoveElement(elem) {
|
||||||
|
|
||||||
// https://msdn.microsoft.com/en-us/library/hh772507(v=vs.85).aspx
|
// https://msdn.microsoft.com/en-us/library/hh772507(v=vs.85).aspx
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @type {HTMLOptionsCollection|any[]}
|
||||||
|
*/
|
||||||
const elemAudioTracks = elem.audioTracks || [];
|
const elemAudioTracks = elem.audioTracks || [];
|
||||||
console.debug(`found ${elemAudioTracks.length} audio tracks`);
|
console.debug(`found ${elemAudioTracks.length} audio tracks`);
|
||||||
|
|
||||||
for (const [i, audioTrack] of elemAudioTracks.entries()) {
|
for (const [i, audioTrack] of Array.from(elemAudioTracks).entries()) {
|
||||||
if (audioIndex === i) {
|
if (audioIndex === i) {
|
||||||
console.debug(`setting audio track ${i} to enabled`);
|
console.debug(`setting audio track ${i} to enabled`);
|
||||||
audioTrack.enabled = true;
|
audioTrack.enabled = true;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue