Skip to content
This repository has been archived by the owner on Sep 30, 2021. It is now read-only.

Commit

Permalink
startsWith() not supported in IE
Browse files Browse the repository at this point in the history
  • Loading branch information
phloxic committed Jul 7, 2017
1 parent 523f6a7 commit 2b2a5f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions flowplayer.dashjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -92,13 +92,13 @@
var representations = aset.Representation_asArray,
mimeType = aset.mimeType || representations[0].mimeType;

if (mimeType.startsWith("video/")) {
if (mimeType.indexOf("video/") === 0) {
vsets = vsets.concat(representations.filter(function (repr) {
var codecs = (repr.mimeType || mimeType) + ";codecs=" + repr.codecs;

return mse.isTypeSupported(codecs);
}));
} else if (mimeType.startsWith("audio/") && !audioBandwidth) {
} else if (mimeType.indexOf("audio/") === 0 && !audioBandwidth) {
// too simple: audio tracks may have different bitrates
audioBandwidth = representations[0].bandwidth;
}
Expand Down

0 comments on commit 2b2a5f1

Please sign in to comment.