Add unexpected exception handling to AutoSet.
This commit is contained in:
parent
e0a13bfe6a
commit
d896a726a9
1 changed files with 21 additions and 17 deletions
|
@ -2294,6 +2294,7 @@ class PlaybackManager {
|
||||||
}
|
}
|
||||||
|
|
||||||
function autoSetNextTracks(prevSource, mediaSource) {
|
function autoSetNextTracks(prevSource, mediaSource) {
|
||||||
|
try {
|
||||||
if (!prevSource) return;
|
if (!prevSource) return;
|
||||||
|
|
||||||
if (!mediaSource) {
|
if (!mediaSource) {
|
||||||
|
@ -2313,6 +2314,9 @@ class PlaybackManager {
|
||||||
|
|
||||||
rankStreamType(prevSource.DefaultAudioStreamIndex, prevSource, mediaSource, 'Audio');
|
rankStreamType(prevSource.DefaultAudioStreamIndex, prevSource, mediaSource, 'Audio');
|
||||||
rankStreamType(prevSource.DefaultSubtitleStreamIndex, prevSource, mediaSource, 'Subtitle');
|
rankStreamType(prevSource.DefaultSubtitleStreamIndex, prevSource, mediaSource, 'Subtitle');
|
||||||
|
} catch (e) {
|
||||||
|
console.error(`AutoSet - Caught unexpected error: ${e}`);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function playAfterBitrateDetect(maxBitrate, item, playOptions, onPlaybackStartedFn, prevSource) {
|
function playAfterBitrateDetect(maxBitrate, item, playOptions, onPlaybackStartedFn, prevSource) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue