Merge pull request #667 from friday/fix/caption-feature-detection
Fix 'TypeError: Cannot read property 'kind' of null' in captions feat…
This commit is contained in:
commit
ad105877ed
@ -2448,7 +2448,7 @@
|
||||
});
|
||||
|
||||
// Check if suported kind
|
||||
var supported = utils.inArray(['captions', 'subtitles'], player.captions.currentTrack.kind);
|
||||
var supported = utils.inArray(['captions', 'subtitles'], player.captions.currentTrack && player.captions.currentTrack.kind);
|
||||
|
||||
if (utils.is.track(player.captions.currentTrack) && supported) {
|
||||
utils.on(player.captions.currentTrack, 'cuechange', setActiveCue);
|
||||
|
Loading…
x
Reference in New Issue
Block a user