From 07351ada80d555bc661fbe43aa9fe5a08fd71bc6 Mon Sep 17 00:00:00 2001 From: Trevor Cook Date: Mon, 26 Aug 2013 16:31:07 -0700 Subject: [PATCH] Close GH-632: Ensure tech is defined before checking tech.isReady_ fixes #631. --- src/js/player.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/js/player.js b/src/js/player.js index 1799f5b57f..ad2e0f2ec0 100644 --- a/src/js/player.js +++ b/src/js/player.js @@ -456,12 +456,7 @@ vjs.Player.prototype.techCall = function(method, arg){ // Get calls can't wait for the tech, and sometimes don't need to. vjs.Player.prototype.techGet = function(method){ - // Make sure there is a tech - // if (!this.tech) { - // return; - // } - - if (this.tech.isReady_) { + if (this.tech && this.tech.isReady_) { // Flash likes to die and reload when you hide or reposition it. // In these cases the object methods go away and we get errors.