Skip to content

Commit

Permalink
Guard against null values in S2.FX.(setReady|ready).
Browse files Browse the repository at this point in the history
  • Loading branch information
savetheclocktower committed Sep 26, 2010
1 parent a3685a1 commit 34cbacc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/effects/base.js
Expand Up @@ -103,6 +103,7 @@ Object.extend(S2.FX, {
},

ready: function(element) {
if (!element) return;
var table = this._ready;
var uid = element._prototypeUID;
if (!uid) return true;
Expand All @@ -112,8 +113,8 @@ Object.extend(S2.FX, {
},

setReady: function(element, bool) {
var table = this._ready;
var uid = element._prototypeUID;
if (!element) return;
var table = this._ready, uid = element._prototypeUID;
if (!uid) {
element.getStorage();
uid = element._prototypeUID;
Expand Down

0 comments on commit 34cbacc

Please sign in to comment.