aboutsummaryrefslogtreecommitdiffstats
path: root/src/core.js
diff options
context:
space:
mode:
authorJohn Resig <jeresig@gmail.com>2009-08-27 19:22:48 +0000
committerJohn Resig <jeresig@gmail.com>2009-08-27 19:22:48 +0000
commit957cd6fb2a2b7b8cfe9ac6b3f2b3cc2bc8163449 (patch)
treecc2c7d228ca7ff133ee29942aababbdb1c5d91b7 /src/core.js
parentf52c4a3d5fb69f143d90f9a032e2a004c36ccae3 (diff)
downloadjquery-957cd6fb2a2b7b8cfe9ac6b3f2b3cc2bc8163449.tar.gz
jquery-957cd6fb2a2b7b8cfe9ac6b3f2b3cc2bc8163449.zip
Tweaked the isXMLDoc iframe test case to test the document, not the body element (which doesn't exist in IE). Also made the isXMLDoc code handle cases where elem is null, undefined, etc.
Diffstat (limited to 'src/core.js')
-rw-r--r--src/core.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core.js b/src/core.js
index 890e9a2df..23b96442e 100644
--- a/src/core.js
+++ b/src/core.js
@@ -316,7 +316,7 @@ jQuery.extend({
isXMLDoc: function( elem ) {
// documentElement is verified for cases where it doesn't yet exist
// (such as loading iframes in IE - #4833)
- return ((elem.ownerDocument || elem).documentElement || 0).nodeName !== "HTML";
+ return ((elem ? elem.ownerDocument || elem : 0).documentElement || 0).nodeName !== "HTML";
},
// Evalulates a script in a global context