mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
fix: ensure secondary index is valid
This commit is contained in:
parent
4ca927991f
commit
3c0ace3386
1 changed files with 5 additions and 1 deletions
|
@ -2387,7 +2387,11 @@ class PlaybackManager {
|
|||
console.debug(`AutoSet ${streamType} - Using ${bestStreamIndex} score ${bestStreamScore}.`);
|
||||
if (streamType == 'Subtitle') {
|
||||
if (isSecondarySubtitle) {
|
||||
if (self.trackHasSecondarySubtitleSupport(mediaSource.MediaStreams[bestStreamIndex])) {
|
||||
mediaSource.DefaultSecondarySubtitleStreamIndex = bestStreamIndex;
|
||||
} else {
|
||||
mediaSource.DefaultSecondarySubtitleStreamIndex = -1;
|
||||
}
|
||||
} else {
|
||||
mediaSource.DefaultSubtitleStreamIndex = bestStreamIndex;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue