removed jqLite warning

This commit is contained in:
Misko Hevery 2011-04-12 15:18:08 -07:00
parent 26e651996a
commit f243c6aeda

View file

@ -55,17 +55,17 @@
try { try {
globalVars[varKey] = window[prop]; globalVars[varKey] = window[prop];
} catch(e) {} //ignore properties that throw exception when accessed (common in FF) } catch(e) {} //ignore properties that throw exception when accessed (common in FF)
} else if (globalVars[varKey] !== window[prop] && !isActuallyNaN(window[prop])) { } else if (globalVars[varKey] !== window[prop] && !isActuallyNaN(window[prop]) && prop != 'jqLite') {
clobbered.push(prop); clobbered.push(prop);
console.error("Global variable clobbered by script " + file + "! Variable name: " + prop); console.error("Global variable clobbered by script " + file + "! Variable name: " + prop);
globalVars[varKey] = window[prop]; globalVars[varKey] = window[prop];
} }
} }
for (varKey in globalVars) { for (varKey in globalVars) {
prop = varKey.substr(11); prop = varKey.substr(11);
if (clobbered.indexOf(prop) == -1 && if (clobbered.indexOf(prop) == -1 &&
prop != 'event' && prop != 'event' &&
prop != 'jqLite' &&
!isActuallyNaN(globalVars[varKey]) && !isActuallyNaN(globalVars[varKey]) &&
globalVars[varKey] !== window[prop]) { globalVars[varKey] !== window[prop]) {