1
0
mirror of https://github.com/videojs/video.js.git synced 2025-07-15 01:34:23 +02:00

be case insensitive

This commit is contained in:
Gary Katsevman
2014-03-13 18:25:03 -04:00
parent e35083bc28
commit 252ad3f466

View File

@ -306,10 +306,11 @@ vjs.Html5.disposeMediaElement = function(el){
// Android 4.0 and above can play HLS to some extent but it reports being unable to do so // Android 4.0 and above can play HLS to some extent but it reports being unable to do so
if (vjs.ANDROID_VERSION >= 4.0) { if (vjs.ANDROID_VERSION >= 4.0) {
(function() { (function() {
var canPlayType = HTMLVideoElement.prototype.canPlayType; var canPlayType = HTMLVideoElement.prototype.canPlayType,
mpegurlRE = /^application\/(?:x-|vnd\.apple\.)mpegurl$/i;
HTMLVideoElement.prototype.canPlayType = function(type) { HTMLVideoElement.prototype.canPlayType = function(type) {
if (type && type === 'application/x-mpegURL' || type === 'application/vnd.apple.mpegURL') { if (type && mpegurlRE.test(type)) {
return "maybe"; return "maybe";
} }
return canPlayType.call(video.constructor.prototype, type); return canPlayType.call(video.constructor.prototype, type);