Fix for potential issue with .tagName
This commit is contained in:
parent
1532f2ab23
commit
ae5a816df1
2
dist/plyr.js
vendored
2
dist/plyr.js
vendored
File diff suppressed because one or more lines are too long
@ -644,7 +644,7 @@
|
||||
player.media.removeAttribute("controls");
|
||||
|
||||
// Set media type
|
||||
player.type = (player.media.tagName == "VIDEO" ? "video" : "audio");
|
||||
player.type = player.media.tagName.toLowerCase();
|
||||
|
||||
// Add type class
|
||||
_toggleClass(player.container, config.classes[player.type], true);
|
||||
@ -1357,7 +1357,7 @@
|
||||
|
||||
// Disabled for <video> for iPhone
|
||||
// Since it doesn't allow customisation
|
||||
if (element.querySelectorAll("audio, video")[0].tagName === "VIDEO"
|
||||
if (element.querySelectorAll("audio, video")[0].tagName.toLowerCase() === "video"
|
||||
&& /iPhone/i.test(navigator.userAgent)) {
|
||||
continue;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user