Skip to content

Commit

Permalink
Use function statement for videojs
Browse files Browse the repository at this point in the history
This is a fix for IE8 where the name of a named function
expression is different from the variable that function is
assigned to. This is an issue because our version of babel outputs
functions like that.
Fixes #3064 again.
  • Loading branch information
gkatsev committed Jun 6, 2016
1 parent 40cf273 commit b9cc347
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/video.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ if (typeof HTMLVideoElement === 'undefined') {
* @mixes videojs
* @method videojs
*/
let videojs = function(id, options, ready){
function videojs(id, options, ready){
let tag; // Element of ID

// Allow for element or ID to be passed in
Expand Down Expand Up @@ -99,7 +99,7 @@ let videojs = function(id, options, ready){
// Element may have a player attr referring to an already created player instance.
// If not, set up a new player and return the instance.
return tag['player'] || Player.players[tag.playerId] || new Player(tag, options, ready);
};
}

// Add default styles
if (window.VIDEOJS_NO_DYNAMIC_STYLE !== true) {
Expand Down

0 comments on commit b9cc347

Please sign in to comment.