File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -5607,11 +5607,14 @@ shaka.Player = class extends shaka.util.FakeEventTarget {
5607
5607
} ;
5608
5608
const selectSrcEqualsMode = ( ) => {
5609
5609
if ( this . video_ && this . video_ . audioTracks ) {
5610
+ const LanguageUtils = shaka . util . LanguageUtils ;
5611
+ const inputLanguage = LanguageUtils . normalize ( audioTrack . language ) ;
5610
5612
const audioTracks = Array . from ( this . video_ . audioTracks ) ;
5611
5613
let trackMatch = null ;
5612
5614
for ( const track of audioTracks ) {
5615
+ const trackLanguage = track . language || 'und' ;
5613
5616
if ( track . label == audioTrack . label &&
5614
- track . language == audioTrack . language &&
5617
+ LanguageUtils . normalize ( trackLanguage ) == inputLanguage &&
5615
5618
track . kind == audioTrack . roles [ 0 ] ) {
5616
5619
trackMatch = track ;
5617
5620
break ;
You can’t perform that action at this time.
0 commit comments